diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2020-12-23 13:16:31 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2020-12-26 14:51:15 +0100 |
commit | a3d0091d185f39eddabf4d372ebe0ac3061dbb89 (patch) | |
tree | 4d70cedc274972ccc21b6b8e7105f042090cf5d6 /oox | |
parent | af791fb775e35c11ad01c42a7085dd121ab9c7a6 (diff) |
New loplugin:stringliteralvar
See the comment at the top of compilerplugins/clang/stringliteralvar.cxx for
details.
(Turned some affected variables in included files into inline variables, to
avoid GCC warnings about unused variables.)
Change-Id: Ie77219e6adfdaaceaa8b4e590b08971f2f04c83a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108239
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'oox')
-rw-r--r-- | oox/qa/unit/drawingml.cxx | 2 | ||||
-rw-r--r-- | oox/qa/unit/mathml.cxx | 2 | ||||
-rw-r--r-- | oox/qa/unit/shape.cxx | 2 | ||||
-rw-r--r-- | oox/qa/unit/vml.cxx | 2 | ||||
-rw-r--r-- | oox/source/ole/oleobjecthelper.cxx | 2 |
5 files changed, 5 insertions, 5 deletions
diff --git a/oox/qa/unit/drawingml.cxx b/oox/qa/unit/drawingml.cxx index c7e72d458194..e5896b0b49ed 100644 --- a/oox/qa/unit/drawingml.cxx +++ b/oox/qa/unit/drawingml.cxx @@ -95,7 +95,7 @@ void OoxDrawingmlTest::loadAndReload(const OUString& rURL, const OUString& rFilt mxComponent = loadFromDesktop(aTempFile.GetURL()); } -char const DATA_DIRECTORY[] = "/oox/qa/unit/data/"; +OUStringLiteral const DATA_DIRECTORY = u"/oox/qa/unit/data/"; CPPUNIT_TEST_FIXTURE(OoxDrawingmlTest, testTransparentText) { diff --git a/oox/qa/unit/mathml.cxx b/oox/qa/unit/mathml.cxx index bb629ccc9097..87bdcaee3d9a 100644 --- a/oox/qa/unit/mathml.cxx +++ b/oox/qa/unit/mathml.cxx @@ -42,7 +42,7 @@ void OoxMathmlTest::tearDown() test::BootstrapFixture::tearDown(); } -char const DATA_DIRECTORY[] = "/oox/qa/unit/data/"; +OUStringLiteral const DATA_DIRECTORY = u"/oox/qa/unit/data/"; CPPUNIT_TEST_FIXTURE(OoxMathmlTest, testImportCharacters) { diff --git a/oox/qa/unit/shape.cxx b/oox/qa/unit/shape.cxx index a57c779d00fd..24ec173ce9d5 100644 --- a/oox/qa/unit/shape.cxx +++ b/oox/qa/unit/shape.cxx @@ -18,7 +18,7 @@ using namespace ::com::sun::star; -char const DATA_DIRECTORY[] = "/oox/qa/unit/data/"; +OUStringLiteral const DATA_DIRECTORY = u"/oox/qa/unit/data/"; /// oox shape tests. class OoxShapeTest : public test::BootstrapFixture, public unotest::MacrosTest diff --git a/oox/qa/unit/vml.cxx b/oox/qa/unit/vml.cxx index ec64a08c3fcf..d6e79a3da956 100644 --- a/oox/qa/unit/vml.cxx +++ b/oox/qa/unit/vml.cxx @@ -19,7 +19,7 @@ using namespace ::com::sun::star; -char const DATA_DIRECTORY[] = "/oox/qa/unit/data/"; +OUStringLiteral const DATA_DIRECTORY = u"/oox/qa/unit/data/"; /// oox vml tests. class OoxVmlTest : public test::BootstrapFixture, public unotest::MacrosTest diff --git a/oox/source/ole/oleobjecthelper.cxx b/oox/source/ole/oleobjecthelper.cxx index 6716ac1ebb29..5cc2b789778a 100644 --- a/oox/source/ole/oleobjecthelper.cxx +++ b/oox/source/ole/oleobjecthelper.cxx @@ -89,7 +89,7 @@ void SaveInteropProperties(uno::Reference<frame::XModel> const& xModel, OUString const& rObjectName, OUString const*const pOldObjectName, OUString const& rProgId) { - static const char sEmbeddingsPropName[] = "EmbeddedObjects"; + static const OUStringLiteral sEmbeddingsPropName = u"EmbeddedObjects"; // get interop grab bag from document uno::Reference<beans::XPropertySet> const xDocProps(xModel, uno::UNO_QUERY); |