summaryrefslogtreecommitdiff
path: root/sal/qa
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2020-12-20 10:50:26 +0100
committerStephan Bergmann <sbergman@redhat.com>2020-12-20 14:26:49 +0100
commit22f7411ecfe0ecc2a62bbc85a6ed27977df03e89 (patch)
tree299975af2922658d2967831193bd8636459a7886 /sal/qa
parentff07da5d888648e0343aabe1f533790029470165 (diff)
Remove the OUString vs. std::u16string_view comparison operators again
...that were introduced in e6dfaf9f44f9939abc338c83b3024108431d0f69 "Turn OUStringLiteral into a consteval'ed, static-refcound rtl_uString" to avoid ambiguities, but which is no longer an issue since 46c5de832868d2812448b2caace3eeaa9237b9f6 "make *String(string_view) constructors explicit" Change-Id: I0a7a3fe23412f77fa85fb7e90f04e22f9abd9230 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108044 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'sal/qa')
-rw-r--r--sal/qa/rtl/strings/test_strings_defaultstringview.cxx18
1 files changed, 9 insertions, 9 deletions
diff --git a/sal/qa/rtl/strings/test_strings_defaultstringview.cxx b/sal/qa/rtl/strings/test_strings_defaultstringview.cxx
index a188886e5d49..591688b31c3c 100644
--- a/sal/qa/rtl/strings/test_strings_defaultstringview.cxx
+++ b/sal/qa/rtl/strings/test_strings_defaultstringview.cxx
@@ -52,19 +52,19 @@ class Test : public CppUnit::TestFixture
OUString("foo").startsWithIgnoreAsciiCase(std::u16string_view()));
CPPUNIT_ASSERT_EQUAL(true, OUString("foo").endsWith(std::u16string_view()));
CPPUNIT_ASSERT_EQUAL(true, OUString("foo").endsWithIgnoreAsciiCase(std::u16string_view()));
- OUString const foo("foo"); // avoid loplugin:stringconstant
+ OUString const foo("foo"); // avoid loplugin:stringconstant, loplugin:stringview
CPPUNIT_ASSERT_EQUAL(false, foo == std::u16string_view());
CPPUNIT_ASSERT_EQUAL(true, foo != std::u16string_view());
- CPPUNIT_ASSERT_EQUAL(false, OUString("foo") < std::u16string_view());
- CPPUNIT_ASSERT_EQUAL(false, OUString("foo") <= std::u16string_view());
- CPPUNIT_ASSERT_EQUAL(true, OUString("foo") > std::u16string_view());
- CPPUNIT_ASSERT_EQUAL(true, OUString("foo") >= std::u16string_view());
+ CPPUNIT_ASSERT_EQUAL(false, foo < std::u16string_view());
+ CPPUNIT_ASSERT_EQUAL(false, foo <= std::u16string_view());
+ CPPUNIT_ASSERT_EQUAL(true, foo > std::u16string_view());
+ CPPUNIT_ASSERT_EQUAL(true, foo >= std::u16string_view());
CPPUNIT_ASSERT_EQUAL(false, std::u16string_view() == foo);
CPPUNIT_ASSERT_EQUAL(true, std::u16string_view() != foo);
- CPPUNIT_ASSERT_EQUAL(true, std::u16string_view() < OUString("foo"));
- CPPUNIT_ASSERT_EQUAL(true, std::u16string_view() <= OUString("foo"));
- CPPUNIT_ASSERT_EQUAL(false, std::u16string_view() > OUString("foo"));
- CPPUNIT_ASSERT_EQUAL(false, std::u16string_view() >= OUString("foo"));
+ CPPUNIT_ASSERT_EQUAL(true, std::u16string_view() < foo);
+ CPPUNIT_ASSERT_EQUAL(true, std::u16string_view() <= foo);
+ CPPUNIT_ASSERT_EQUAL(false, std::u16string_view() > foo);
+ CPPUNIT_ASSERT_EQUAL(false, std::u16string_view() >= foo);
CPPUNIT_ASSERT_EQUAL(sal_Int32(-1), OUString("foo").indexOf(std::u16string_view()));
CPPUNIT_ASSERT_EQUAL(sal_Int32(-1), OUString("foo").lastIndexOf(std::u16string_view()));
CPPUNIT_ASSERT_EQUAL(sal_Int32(-1), OUString("foo").lastIndexOf(std::u16string_view(), 3));