Remove wxUSE_STL which is not really used any longer

wxString is always based on std::[w]string since 2c0c727f49 (Remove wx
own wxStringImpl implementation, 2022-11-16) and all containers use
standard containers by default too now -- and there is a separate
wxUSE_STD_CONTAINERS for this anyhow.

The only remaining use of wxUSE_STL was as the default value for
wxUSE_STD_STRING_CONV_IN_WXSTRING option, but it's not really needed
for this neither, and this option can just be set to 0 by default.

Also add wxUSE_CHAR_CONV_IN_WXSTRING which can now be set to 0 too to
disable all unwanted implicit conversions (even "safe" ones, to wide
strings, in addition to the unsafe ones to narrow strings that could be
already disabled with wxUSE_UNSAFE_WXSTRING_CONV) to allow people who
don't want to have any implicit conversions at all to do it.

Keep --enable-stl configure option for compatibility, but warn if it is
used to tell people that it is not needed any longer.
This commit is contained in:
Vadim Zeitlin 2023-04-15 15:42:10 +01:00
parent d65eed50fa
commit 35c35c235e
22 changed files with 315 additions and 248 deletions

View file

@ -1018,8 +1018,7 @@ TEST_CASE("StringCStrDataImplicitConversion", "[wxString]")
CHECK( CheckStrConstWChar(s, s.c_str()) );
CHECK( CheckStrConstChar(s, s.c_str()) );
// implicit conversion of wxString is not available in STL build
#if !wxUSE_STL
#if wxUSE_CHAR_CONV_IN_WXSTRING
CHECK( CheckStrConstWChar(s, s) );
#if wxUSE_UNSAFE_WXSTRING_CONV
CHECK( CheckStrConstChar(s, s) );