dimanche 26 juillet 2015

Code is not compiling while trying to use typeid

The following program failed to compile :

 #include <iostream>

 int main()
 {
   short x(3);
   int y (8);
   std::cout << typeid (x + y).name ();
   return 0;
  }

I am using Code::Blocks. Did I missed something?

Aucun commentaire:

Enregistrer un commentaire