Original Post
I have tried to implement the singleton design pattern. I chose the usual(?) template version which can be inherited. But I had to find out that it does not work with DLLs.
If I do my singleton like this:
templateThe Get() Method will return different pointers in the application and in the DLL. But if I wrap my Direct3D Device or whatever within a singleton it should be the same in the DLL as in the application. Why does it not work?class CSingleton { T * Get(); ... }; class CConcreteSingleton : public CSingleton { ... };