diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2020-12-22 20:14:43 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2020-12-23 09:14:01 +0100 |
commit | b5c532154cb974de04f2a430712cd947e1bcc98a (patch) | |
tree | 51bba487fffc62a4d197aa15238fd298883487cf /sal | |
parent | 1edf1871079518f90e447c3de9df0c4ef5e1e3e4 (diff) |
Use char16_t string literals
Change-Id: I0a8b577957ac1d4cad5fc1163f244012a8391a77
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108216
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'sal')
-rw-r--r-- | sal/qa/rtl/uri/rtl_testuri.cxx | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/sal/qa/rtl/uri/rtl_testuri.cxx b/sal/qa/rtl/uri/rtl_testuri.cxx index fc7e1d30a751..e2d076b19127 100644 --- a/sal/qa/rtl/uri/rtl_testuri.cxx +++ b/sal/qa/rtl/uri/rtl_testuri.cxx @@ -358,7 +358,7 @@ void Test::test_Uri() { // Check encode with unusual text encodings: { - sal_Unicode const aText1U[] = { ' ', '!', 0x0401, 0x045F, 0 }; + sal_Unicode const aText1U[] = u" !\u0401\u045F"; aText1 = OUString(aText1U); aText2 = "%20!%A1%FF"; CPPUNIT_ASSERT_EQUAL_MESSAGE( @@ -374,10 +374,10 @@ void Test::test_Uri() { aText2, rtl_UriDecodeWithCharset, RTL_TEXTENCODING_ISO_8859_5)); } { - sal_Unicode const aText1U[] = { ' ', '!', 0x0401, 0x0700, 0x045F, 0 }; + sal_Unicode const aText1U[] = u" !\u0401\u0700\u045F"; aText1 = OUString(aText1U); - sal_Unicode const aText2U[] = { - '%', '2', '0', '!', '%', 'A', '1', 0x0700, '%', 'F', 'F', 0 }; + sal_Unicode const aText2U[] = + u"%20!%A1\u0700%FF"; aText2 = OUString(aText2U); CPPUNIT_ASSERT_EQUAL_MESSAGE( "failure 21", @@ -393,7 +393,7 @@ void Test::test_Uri() { } #if WITH_LOCALE_ALL || WITH_LOCALE_zh { - sal_Unicode const aText1U[] = { ' ', '!', 0x028A, 0xD849, 0xDD13, 0 }; + sal_Unicode const aText1U[] = u" !\u028A\U00022513"; aText1 = OUString(aText1U); aText2 = "%20!%81%30%B1%33%95%39%C5%37"; CPPUNIT_ASSERT_EQUAL_MESSAGE( @@ -412,7 +412,7 @@ void Test::test_Uri() { // Check strict mode: { - sal_Unicode const aText1U[] = { ' ', '!', 0x0401, 0x0700, 0x045F, 0 }; + sal_Unicode const aText1U[] = u" !\u0401\u0700\u045F"; aText1 = OUString(aText1U); aText2 = OUString(); CPPUNIT_ASSERT_EQUAL_MESSAGE( @@ -452,7 +452,7 @@ void Test::test_Uri() { } { aText1 = "%81%30%B1%33"; - sal_Unicode const aText2U[] = { 0x028A, 0 }; + sal_Unicode const aText2U[] = u"\u028A"; aText2 = OUString(aText2U); CPPUNIT_ASSERT_EQUAL_MESSAGE( "failure 27", @@ -462,7 +462,7 @@ void Test::test_Uri() { } { aText1 = "%810%B13"; - sal_Unicode const aText2U[] = { 0x028A, 0 }; + sal_Unicode const aText2U[] = u"\u028A"; aText2 = OUString(aText2U); CPPUNIT_ASSERT_EQUAL_MESSAGE( "failure 28", @@ -484,7 +484,7 @@ void Test::test_Uri() { RTL_TEXTENCODING_UTF8)); } { - sal_Unicode const aText1U[] = { 0x00EA, 0 }; + sal_Unicode const aText1U[] = u"\u00EA"; aText1 = OUString(aText1U); aText2 = "%C3%AA"; CPPUNIT_ASSERT_EQUAL_MESSAGE( @@ -495,7 +495,7 @@ void Test::test_Uri() { RTL_TEXTENCODING_UTF8)); } { - sal_Unicode const aText1U[] = { ' ', '!', 0x0401, 0x0700, 0x045F, 0 }; + sal_Unicode const aText1U[] = u" !\u0401\u0700\u045F"; aText1 = OUString(aText1U); aText2 = OUString(); CPPUNIT_ASSERT_EQUAL_MESSAGE( |