math constants: simplify and generalize promotion with constants.