From c4907129f49b9bba2ea25b7aa2d7442948d54493 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Fri, 26 Feb 2016 13:10:59 +0100 Subject: [PATCH] Don't export container classes from DLLs when using STL containers Exporting these classes doesn't seem necessary as they only have inline functions and doing it results in problems with MSVC as it also, apparently, exports the corresponding specialization of std::vector from the wxWidgets DLLs which can clash with the use of std::vector in the user code or even in 3rd party libraries included in wx itself, such as Scintilla, so this change fixes link errors in "DLL Debug" build configuration when using MSVC. Closes #10884. --- include/wx/dynarray.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/wx/dynarray.h b/include/wx/dynarray.h index 6495030f0c..a15936c394 100644 --- a/include/wx/dynarray.h +++ b/include/wx/dynarray.h @@ -114,7 +114,7 @@ private: _WX_DECLARE_BASEARRAY_2(T, name, name##_Predicate, classexp) #define _WX_DECLARE_BASEARRAY_2(T, name, predicate, classexp) \ -classexp name : public std::vector \ +class name : public std::vector \ { \ typedef predicate Predicate; \ typedef predicate::CMPFUNC SCMPFUNC; \