
Joaquín Mª López Muñoz wrote: . . . Good question. I should have explained of course. Well vacpp has only in some circurmstances a problem with the in class member initialization. For instance following does not work (confirmed by IBM):
class A { public: static const int value = true ; } ;
int main() { int v1 = A::value ; // does work bool v2 = A::value ; // does not work return 0 ; } ;
Hello, I know i argue with eminent C++ specialists in this group, but i think the code above is not correct. To my best knowledge even with the inclass line static const int value = true ; you have to give a definition outside of the class: int A::value; Apart from that return 0; should be unnecessary and there is a spurious semicolon after the last brace; Greetings Franz