summaryrefslogtreecommitdiff
path: root/sw/source/ui
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2021-04-15 09:39:14 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2021-04-15 13:54:53 +0200
commit46ce0d28b4c765076c7871358375c4e85e44534b (patch)
treeb17378d5258a51185001eac455a764897e6dda11 /sw/source/ui
parent00f7309fb786efcc0bbca04fb29de80f275a16ba (diff)
loplugin:stringliteralvar look for assignments
to O[U]String from char array literals, we can convert the char literals to O[U]StringLiteral and avoid a runtime allocation Change-Id: I15d8dddb2cd428b90740e39f20daf98e0941aa6d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114125 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw/source/ui')
-rw-r--r--sw/source/ui/vba/vbalisthelper.cxx16
1 files changed, 8 insertions, 8 deletions
diff --git a/sw/source/ui/vba/vbalisthelper.cxx b/sw/source/ui/vba/vbalisthelper.cxx
index a6597a539145..fa7d69a23d20 100644
--- a/sw/source/ui/vba/vbalisthelper.cxx
+++ b/sw/source/ui/vba/vbalisthelper.cxx
@@ -38,14 +38,14 @@ constexpr OUStringLiteral UNO_NAME_CHAR_STYLE_NAME = u"CharStyleName";
constexpr OUStringLiteral UNO_NAME_NUMBERING_TYPE = u"NumberingType";
constexpr OUStringLiteral UNO_NAME_BULLET_CHAR = u"BulletChar";
-const sal_Unicode CHAR_CLOSED_DOT[] = u"\u2022";
-const char CHAR_EMPTY_DOT[] = "o";
-const sal_Unicode CHAR_SQUARE[] = u"\u2540";
-const sal_Unicode CHAR_STAR_SYMBOL[] = u"\u272A";
-const sal_Unicode CHAR_FOUR_DIAMONDS[] = u"\u2756";
-const sal_Unicode CHAR_DIAMOND[] = u"\u2726";
-const sal_Unicode CHAR_ARROW[] = u"\u27A2";
-const sal_Unicode CHAR_CHECK_MARK[] = u"\u2713";
+constexpr OUStringLiteral CHAR_CLOSED_DOT = u"\u2022";
+constexpr OUStringLiteral CHAR_EMPTY_DOT = u"o";
+constexpr OUStringLiteral CHAR_SQUARE = u"\u2540";
+constexpr OUStringLiteral CHAR_STAR_SYMBOL = u"\u272A";
+constexpr OUStringLiteral CHAR_FOUR_DIAMONDS = u"\u2756";
+constexpr OUStringLiteral CHAR_DIAMOND = u"\u2726";
+constexpr OUStringLiteral CHAR_ARROW = u"\u27A2";
+constexpr OUStringLiteral CHAR_CHECK_MARK = u"\u2713";
SwVbaListHelper::SwVbaListHelper( const css::uno::Reference< css::text::XTextDocument >& xTextDoc, sal_Int32 nGalleryType, sal_Int32 nTemplateType ) : mxTextDocument( xTextDoc ), mnGalleryType( nGalleryType ), mnTemplateType( nTemplateType )
{