1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
#ifndef _MSC_VER # define winexport #else # ifdef autoexport_EXPORTS # define winexport # else # define winexport __declspec(dllimport) # endif #endif class Hello { public: static winexport int Data; void real(); static void operator delete[](void*); static void operator delete(void*); };