basic/source/sbx/sbxres.cxx |   94 ++++++++++++++++++++++----------------------
 1 file changed, 47 insertions(+), 47 deletions(-)

New commits:
commit a123c5b39a4e936121f51c4fc705f5652db3a700
Author:     Arnaud VERSINI <arnaud.vers...@pm.me>
AuthorDate: Mon Apr 29 10:00:04 2024 +0200
Commit:     Arnaud Versini <arnaud.vers...@pm.me>
CommitDate: Sun May 5 14:44:04 2024 +0200

    basic : use more OUString literals
    
    Change-Id: I38f57c64c0d110e892982eaed2619c0915fe93b1
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166825
    Tested-by: Jenkins
    Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk>
    Reviewed-by: Arnaud Versini <arnaud.vers...@pm.me>

diff --git a/basic/source/sbx/sbxres.cxx b/basic/source/sbx/sbxres.cxx
index 125969e3efd9..d29383cf076c 100644
--- a/basic/source/sbx/sbxres.cxx
+++ b/basic/source/sbx/sbxres.cxx
@@ -22,59 +22,59 @@
 
 #include <rtl/ustring.hxx>
 
-static const char* pSbxRes[] = {
-    "Empty",
-    "Null",
-    "Integer",
-    "Long",
-    "Single",
-    "Double",
-    "Currency",
-    "Date",
-    "String",
-    "Object",
-    "Error",
-    "Boolean",
-    "Variant",
-    "Any",
-    "Type14",
-    "Type15",
-    "Char",
-    "Byte",
-    "UShort",
-    "ULong",
-    "Long64",
-    "ULong64",
-    "Int",
-    "UInt",
-    "Void",
-    "HResult",
-    "Pointer",
-    "DimArray",
-    "CArray",
-    "Any",
-    "LpStr",
-    "LpWStr",
-    " As ",
-    "Optional ",
-    "Byref ",
+constexpr OUString pSbxRes[] = {
+    u"Empty"_ustr,
+    u"Null"_ustr,
+    u"Integer"_ustr,
+    u"Long"_ustr,
+    u"Single"_ustr,
+    u"Double"_ustr,
+    u"Currency"_ustr,
+    u"Date"_ustr,
+    u"String"_ustr,
+    u"Object"_ustr,
+    u"Error"_ustr,
+    u"Boolean"_ustr,
+    u"Variant"_ustr,
+    u"Any"_ustr,
+    u"Type14"_ustr,
+    u"Type15"_ustr,
+    u"Char"_ustr,
+    u"Byte"_ustr,
+    u"UShort"_ustr,
+    u"ULong"_ustr,
+    u"Long64"_ustr,
+    u"ULong64"_ustr,
+    u"Int"_ustr,
+    u"UInt"_ustr,
+    u"Void"_ustr,
+    u"HResult"_ustr,
+    u"Pointer"_ustr,
+    u"DimArray"_ustr,
+    u"CArray"_ustr,
+    u"Any"_ustr,
+    u"LpStr"_ustr,
+    u"LpWStr"_ustr,
+    u" As "_ustr,
+    u"Optional "_ustr,
+    u"Byref "_ustr,
 
-    "Name",
-    "Parent",
-    "Application",
-    "Count",
-    "Add",
-    "Item",
-    "Remove",
+    u"Name"_ustr,
+    u"Parent"_ustr,
+    u"Application"_ustr,
+    u"Count"_ustr,
+    u"Add"_ustr,
+    u"Item"_ustr,
+    u"Remove"_ustr,
 
-    "Error ",   // with blank!
-    "False",
-    "True"
+    u"Error "_ustr,   // with blank!
+    u"False"_ustr,
+    u"True"_ustr
 };
 
 OUString GetSbxRes( StringId nId )
 {
-    return OUString::createFromAscii( ( nId > StringId::LastValue ) ? "???" : 
pSbxRes[ static_cast<int>( nId ) ] );
+    return  ( nId > StringId::LastValue ) ? u"???"_ustr : pSbxRes[ 
static_cast<int>( nId ) ];
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Reply via email to