Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The variable arguments to a variadic function are not checked for type by the compiler.  So, the programmer is responsible for ensuring that they are compatible with the corresponding parameter after the default argument promotions:

  • Integer arguments of types ranked lower than int are promoted to int, if int can hold all the values of that type; otherwise, they are promoted to unsigned int (the "integer promotions").
  • Arguments of type float are promoted to double.

...