ODR violation in wxWeakRef
|Reported by:||minoki||Owned by:||VZ|
Currently, wxWeakRef is implemented differently for complete types and incomplete types. So, the same wxWeakRef<SomeClass> may have different implementation between compilation units (i.e. ODR violation). This may lead to program crash.
wxWeakRef must use the same implementation (or, at least, must have the same data members) whether the type is incomplete or not.
The attached files (mytrackable.h, foo.h, foo.cpp, test.cpp) reproduce the problem.