From 0de59fac73861466aea95796f16a0fe17e083172 Mon Sep 17 00:00:00 2001
From: Noel Grandin <noel.grandin@collabora.co.uk>
Date: Fri, 6 Nov 2020 08:32:47 +0100
Subject: Revert "loplugin:stringbuffer"

This reverts commit f0356b6128bb4e78041d53025ad7c2e0b8e0c299.

Reason for revert: There is a OUStringConcat overload for OUStringBuffer which would have kicked in here, so this is unnecessary

Change-Id: I3bafb6c30bd3a2c1912daf227554889f1e09c78a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105354
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
---
 pyuno/source/module/pyuno.cxx        | 20 ++++++++++----------
 pyuno/source/module/pyuno_module.cxx |  4 ++--
 pyuno/source/module/pyuno_util.cxx   |  6 +++---
 3 files changed, 15 insertions(+), 15 deletions(-)

(limited to 'pyuno')

diff --git a/pyuno/source/module/pyuno.cxx b/pyuno/source/module/pyuno.cxx
index 4cfdab9982d0..25ae588d6d58 100644
--- a/pyuno/source/module/pyuno.cxx
+++ b/pyuno/source/module/pyuno.cxx
@@ -93,13 +93,13 @@ OUString val2str( const void * pVal, typelib_TypeDescriptionReference * pTypeRef
         return "void";
 
     OUStringBuffer buf( 64 );
-    buf.append( "(" ).append( OUString::unacquired(&pTypeRef->pTypeName) ).append( ")" );
+    buf.append( "(" + OUString::unacquired(&pTypeRef->pTypeName) + ")" );
 
     switch (pTypeRef->eTypeClass)
     {
     case typelib_TypeClass_INTERFACE:
     {
-        buf.append( "0x" ).append(
+        buf.append( "0x" +
             OUString::number( reinterpret_cast< sal_IntPtr >(*static_cast<void * const *>(pVal)), 16 ));
         if( VAL2STR_MODE_DEEP == mode )
         {
@@ -162,7 +162,7 @@ OUString val2str( const void * pVal, typelib_TypeDescriptionReference * pTypeRef
 
         for ( sal_Int32 nPos = 0; nPos < nDescr; ++nPos )
         {
-            buf.append( OUString::unacquired(&ppMemberNames[nPos]) ).append( " = " );
+            buf.append( OUString::unacquired(&ppMemberNames[nPos]) + " = " );
             typelib_TypeDescription * pMemberType = nullptr;
             TYPELIB_DANGER_GET( &pMemberType, ppTypeRefs[nPos] );
             buf.append( val2str( static_cast<char const *>(pVal) + pMemberOffsets[nPos], pMemberType->pWeakRef, mode ) );
@@ -219,8 +219,8 @@ OUString val2str( const void * pVal, typelib_TypeDescriptionReference * pTypeRef
         buf.append( (*static_cast<typelib_TypeDescriptionReference * const *>(pVal))->pTypeName );
         break;
     case typelib_TypeClass_STRING:
-        buf.append( "\"").append(
-            OUString::unacquired(&*static_cast<rtl_uString * const *>(pVal)) ).append(
+        buf.append( "\"" +
+            OUString::unacquired(&*static_cast<rtl_uString * const *>(pVal)) +
             "\"" );
         break;
     case typelib_TypeClass_ENUM:
@@ -261,23 +261,23 @@ OUString val2str( const void * pVal, typelib_TypeDescriptionReference * pTypeRef
         buf.append( *static_cast<double const *>(pVal) );
         break;
     case typelib_TypeClass_BYTE:
-        buf.append( "0x").append(
+        buf.append( "0x" +
             OUString::number( static_cast<sal_Int32>(*static_cast<sal_Int8 const *>(pVal)), 16 ));
         break;
     case typelib_TypeClass_SHORT:
-        buf.append( "0x").append(
+        buf.append( "0x" +
             OUString::number( static_cast<sal_Int32>(*static_cast<sal_Int16 const *>(pVal)), 16 ));
         break;
     case typelib_TypeClass_UNSIGNED_SHORT:
-        buf.append( "0x").append(
+        buf.append( "0x" +
             OUString::number( static_cast<sal_Int32>(*static_cast<sal_uInt16 const *>(pVal)), 16 ));
         break;
     case typelib_TypeClass_LONG:
-        buf.append( "0x").append(
+        buf.append( "0x" +
             OUString::number( *static_cast<sal_Int32 const *>(pVal), 16 ));
         break;
     case typelib_TypeClass_UNSIGNED_LONG:
-        buf.append( "0x").append(
+        buf.append( "0x" +
             OUString::number( static_cast<sal_Int64>(*static_cast<sal_uInt32 const *>(pVal)), 16 ));
         break;
     case typelib_TypeClass_HYPER:
diff --git a/pyuno/source/module/pyuno_module.cxx b/pyuno/source/module/pyuno_module.cxx
index 34141029ab58..cb2824d00005 100644
--- a/pyuno/source/module/pyuno_module.cxx
+++ b/pyuno/source/module/pyuno_module.cxx
@@ -112,10 +112,10 @@ public:
         if (initialised[key])
         {
             OUStringBuffer buf;
-            buf.append( "pyuno._createUnoStructHelper: member '").append(key).append("'");
+            buf.append( "pyuno._createUnoStructHelper: member '" + key + "'");
             if ( pos >= 0 )
             {
-                buf.append( " at position ").append(OUString::number(pos));
+                buf.append( " at position " + OUString::number(pos));
             }
             buf.append( " initialised multiple times.");
             throw RuntimeException(buf.makeStringAndClear());
diff --git a/pyuno/source/module/pyuno_util.cxx b/pyuno/source/module/pyuno_util.cxx
index f7cb6a9f4c79..77006c33acac 100644
--- a/pyuno/source/module/pyuno_util.cxx
+++ b/pyuno/source/module/pyuno_util.cxx
@@ -151,7 +151,7 @@ void logException( RuntimeCargo *cargo, const char *intro,
         OUStringBuffer buf( 128 );
         buf.appendAscii( intro );
         appendPointer(buf, ptr);
-        buf.append( "]." ).append( aFunctionName ).append( " = " );
+        buf.append( "]." + aFunctionName + " = " );
         buf.append(
             val2str( data, type.getTypeLibType(), VAL2STR_MODE_SHALLOW ) );
         log( cargo,LogLevel::CALL, buf.makeStringAndClear() );
@@ -170,7 +170,7 @@ void logReply(
     OUStringBuffer buf( 128 );
     buf.appendAscii( intro );
     appendPointer(buf, ptr);
-    buf.append( "]." ).append( aFunctionName ).append( "()=" );
+    buf.append( "]." + aFunctionName + "()=" );
     if( isLog( cargo, LogLevel::ARGS ) )
     {
         buf.append(
@@ -192,7 +192,7 @@ void logCall( RuntimeCargo *cargo, const char *intro,
     OUStringBuffer buf( 128 );
     buf.appendAscii( intro );
     appendPointer(buf, ptr);
-    buf.append( "]." ).append( aFunctionName ).append( "(" );
+    buf.append( "]." + aFunctionName + "(" );
     if( isLog( cargo, LogLevel::ARGS ) )
     {
         for( int i = 0; i < aParams.getLength() ; i ++ )
-- 
cgit