lamemind:
Since Build 930 some of my code won't compile
The error happens when referencing a static variable of a class inside the class itself.
That's no big deal, I can use a global variable...
The new version of the compiler static data members must now be placed.
class CFoo { static int m_x; }; int CFoo::m_x=10; <<--- placing a static member
Place you can:
class SingletonClass { private: static SingletonClass* singleton; public: SingletonClass* get(void) { if (singleton == NULL) { singleton = new SingletonClass(); } return singleton; } }; SingletonClass* SingletonClass::singleton = NULL;
It worked!
Thank you Fleder
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Since Build 930 some of my code won't compile
The error happens when referencing a static variable of a class inside the class itself.
That's no big deal, I can use a global variable...