Hello everyone,
Now compiler prevents (at least in Visual Studio 2008) us from initialize non-const static member variable in this way,
Anyone know why compiler prevents initialize non-const variable in this way? Any side effects or just a fixed rule from C++ Spec?Code:Class Foo { statuc int i = 200; // compile error, must use const static int i = 200; ... };
thanks in advance,
George