X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/05f68f2f84f9dcacfab853a889d7582454042412..9afa58e3b924dbef7fd0d45bb0bbee68fe3aac7d:/tests/benchmarks/strings.cpp?ds=sidebyside diff --git a/tests/benchmarks/strings.cpp b/tests/benchmarks/strings.cpp index 616e371edf..6ea1f53e86 100644 --- a/tests/benchmarks/strings.cpp +++ b/tests/benchmarks/strings.cpp @@ -315,28 +315,28 @@ BENCHMARK_FUNC(StrcmpA) { const wxString& s = GetTestAsciiString(); - return wxCRT_StrcmpA(s, s) == 0; + return wxCRT_StrcmpA(s.c_str(), s.c_str()) == 0; } BENCHMARK_FUNC(StrcmpW) { const wxString& s = GetTestAsciiString(); - return wxCRT_StrcmpW(s, s) == 0; + return wxCRT_StrcmpW(s.wc_str(), s.wc_str()) == 0; } BENCHMARK_FUNC(StricmpA) { const wxString& s = GetTestAsciiString(); - return wxCRT_StricmpA(s, s) == 0; + return wxCRT_StricmpA(s.c_str(), s.c_str()) == 0; } BENCHMARK_FUNC(StricmpW) { const wxString& s = GetTestAsciiString(); - return wxCRT_StricmpW(s, s) == 0; + return wxCRT_StricmpW(s.wc_str(), s.wc_str()) == 0; } BENCHMARK_FUNC(StringCmp) @@ -356,7 +356,7 @@ BENCHMARK_FUNC(StringCmpNoCase) // Also benchmark various native functions under MSW. Surprisingly/annoyingly // they sometimes have vastly better performance than alternatives, especially // for case-sensitive comparison (see #10375). -#ifdef __WXMSW__ +#ifdef __WINDOWS__ #include "wx/msw/wrapwin.h" @@ -400,7 +400,7 @@ BENCHMARK_FUNC(MSWCompareStringIgnoreCase) ) == CSTR_EQUAL; } -#endif // __WXMSW__ +#endif // __WINDOWS__ // ---------------------------------------------------------------------------- // string buffers: wx[W]CharBuffer