cpp/numeric/math/exp2

@1-3@ Computes 2 raised to the given power. @A@ Additional overloads are provided for all integer types, which are treated as.

Return value
If no errors occur, the base-2 exponential of ($2num$) is returned.

If a range error due to overflow occurs, huge_val,, or is returned.

If a range error occurs due to underflow, the correct result (after rounding) is returned.

Error handling
Errors are reported as specified in math_errhandling.

If the implementation supports IEEE floating-point arithmetic (IEC 60559),
 * If the argument is ±0, 1 is returned
 * If the argument is -∞, +0 is returned
 * If the argument is +∞, +∞ is returned
 * If the argument is NaN, NaN is returned