From 896800a7091c2f7d7fc70efaf87b0741dead33bb Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Mon, 8 Feb 2021 15:04:13 +0100 Subject: [PATCH] sal_Unicode is always char16_t in LIBO_INTERNAL_ONLY code now ...since 9ac98e6e3488e434bf4864ecfb13a121784f640b "Finally switch MSVC to sal_Unicode = char16_t, too" Change-Id: I0df169307618aba3f609400312737c6e1e1d3aaf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110581 Tested-by: Jenkins Reviewed-by: Stephan Bergmann --- cppu/qa/test_any.cxx | 37 ++++++++----------------------------- 1 file changed, 8 insertions(+), 29 deletions(-) diff --git a/cppu/qa/test_any.cxx b/cppu/qa/test_any.cxx index 06fa51168b64..de640099f1dc 100644 --- a/cppu/qa/test_any.cxx +++ b/cppu/qa/test_any.cxx @@ -20,7 +20,6 @@ #include #include -#include #include #include @@ -498,13 +497,8 @@ void Test::testByte() { } { sal_Unicode b = '2'; - if (std::is_same< sal_Unicode, sal_uInt16 >::value) { - CPPUNIT_ASSERT_MESSAGE("@sal_Unicode", (a >>= b)); - CPPUNIT_ASSERT_EQUAL_MESSAGE("@sal_Unicode", u'\u0001', b); - } else { - CPPUNIT_ASSERT_MESSAGE("sal_Unicode", !(a >>= b)); - CPPUNIT_ASSERT_EQUAL_MESSAGE("sal_Unicode", u'2', b); - } + CPPUNIT_ASSERT_MESSAGE("sal_Unicode", !(a >>= b)); + CPPUNIT_ASSERT_EQUAL_MESSAGE("sal_Unicode", u'2', b); } { OUString b("2"); @@ -613,13 +607,8 @@ void Test::testShort() { } { sal_Unicode b = '2'; - if (std::is_same< sal_Unicode, sal_uInt16 >::value) { - CPPUNIT_ASSERT_MESSAGE("@sal_Unicode", (a >>= b)); - CPPUNIT_ASSERT_EQUAL_MESSAGE("@sal_Unicode", u'\u0001', b); - } else { - CPPUNIT_ASSERT_MESSAGE("sal_Unicode", !(a >>= b)); - CPPUNIT_ASSERT_EQUAL_MESSAGE("sal_Unicode", u'2', b); - } + CPPUNIT_ASSERT_MESSAGE("sal_Unicode", !(a >>= b)); + CPPUNIT_ASSERT_EQUAL_MESSAGE("sal_Unicode", u'2', b); } { OUString b("2"); @@ -730,13 +719,8 @@ void Test::testUnsignedShort() { } { sal_Unicode b = '2'; - if (std::is_same< sal_Unicode, sal_uInt16 >::value) { - CPPUNIT_ASSERT_MESSAGE("@sal_Unicode", (a >>= b)); - CPPUNIT_ASSERT_EQUAL_MESSAGE("@sal_Unicode", u'\u0001', b); - } else { - CPPUNIT_ASSERT_MESSAGE("sal_Unicode", !(a >>= b)); - CPPUNIT_ASSERT_EQUAL_MESSAGE("sal_Unicode", u'2', b); - } + CPPUNIT_ASSERT_MESSAGE("sal_Unicode", !(a >>= b)); + CPPUNIT_ASSERT_EQUAL_MESSAGE("sal_Unicode", u'2', b); } { OUString b("2"); @@ -1506,13 +1490,8 @@ void Test::testChar() { } { sal_Unicode b = '2'; - if (std::is_same< sal_Unicode, sal_uInt16 >::value) { - CPPUNIT_ASSERT_MESSAGE("@sal_Unicode", !(a >>= b)); - CPPUNIT_ASSERT_EQUAL_MESSAGE("@sal_Unicode", u'2', b); - } else { - CPPUNIT_ASSERT_MESSAGE("sal_Unicode", (a >>= b)); - CPPUNIT_ASSERT_EQUAL_MESSAGE("sal_Unicode", u'1', b); - } + CPPUNIT_ASSERT_MESSAGE("sal_Unicode", (a >>= b)); + CPPUNIT_ASSERT_EQUAL_MESSAGE("sal_Unicode", u'1', b); } { OUString b("2");