class Foo { private: int m_i; public: Foo(int i) : m_i(i) {} }; class FooA { private: const static Foo & m_foo; static Foo & m_foo2; };
Q1> how to initialize a constant static link?
Q2> How to initialize a non-static static link?
Note: You can make changes to the FooA class to illustrate the methods.
source share