Questions marquées «reserved»

2
Une déclaration peut-elle affecter l'espace de noms std?
#include <iostream> #include <cmath> /* Intentionally incorrect abs() which seems to override std::abs() */ int abs(int a) { return a > 0? -a : a; } int main() { int a = abs(-5); int b = std::abs(-5); std::cout<< a << std::endl << b << std::endl; return 0; } Je m'attendais …
96 c++  std  reserved 
En utilisant notre site, vous reconnaissez avoir lu et compris notre politique liée aux cookies et notre politique de confidentialité.
Licensed under cc by-sa 3.0 with attribution required.