From 9b5dad13b56bdde7c40970351af3da3a2c3c9350 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Sun, 13 Oct 2019 08:47:47 +0200 Subject: loplugin:stringadd look for unnecessary temporaries which defeat the *StringConcat optimisation. Also make StringConcat conversions treat a nullptr as an empty string, to match the O*String(char*) constructors. Change-Id: If45f5b4b6a535c97bfeeacd9ec472a7603a52e5b Reviewed-on: https://gerrit.libreoffice.org/80724 Tested-by: Jenkins Reviewed-by: Noel Grandin --- chart2/qa/extras/chart2dump/chart2dump.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'chart2') diff --git a/chart2/qa/extras/chart2dump/chart2dump.cxx b/chart2/qa/extras/chart2dump/chart2dump.cxx index a03f98a0527d..faf8ead6256a 100644 --- a/chart2/qa/extras/chart2dump/chart2dump.cxx +++ b/chart2/qa/extras/chart2dump/chart2dump.cxx @@ -150,7 +150,7 @@ protected: std::string sTemp; getline(m_aReferenceFile, sTemp); OString sAssertMessage = - OString("The reference file does not contain the right content. Maybe it needs an update:") + "The reference file does not contain the right content. Maybe it needs an update:" + OUStringToOString(m_sTestFileName, RTL_TEXTENCODING_UTF8); CPPUNIT_ASSERT_EQUAL_MESSAGE(sAssertMessage.getStr(), OUString("// " + sCheck), OUString(sTemp.data(), sTemp.length(), RTL_TEXTENCODING_UTF8)); getline(m_aReferenceFile, sTemp); @@ -172,7 +172,7 @@ protected: std::string sTemp; getline(m_aReferenceFile, sTemp); OString sAssertMessage = - OString("The reference file does not contain the right content. Maybe it needs an update:") + "The reference file does not contain the right content. Maybe it needs an update:" + OUStringToOString(m_sTestFileName, RTL_TEXTENCODING_UTF8); CPPUNIT_ASSERT_EQUAL_MESSAGE(sAssertMessage.getStr(), OUString("/// " + sNote), OUString(sTemp.data(), sTemp.length(), RTL_TEXTENCODING_UTF8)); } -- cgit