From 042033f1e6da22616cb76c8d950c20c9efecbad5 Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Mon, 28 Dec 2020 17:56:40 +0100 Subject: loplugin:stringviewparam: operator + Change-Id: I044dd21b63d7eb03224675584fa143009c6b6008 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108418 Tested-by: Jenkins Reviewed-by: Stephan Bergmann --- pyuno/source/module/pyuno_impl.hxx | 6 +++--- pyuno/source/module/pyuno_util.cxx | 12 ++++++------ 2 files changed, 9 insertions(+), 9 deletions(-) (limited to 'pyuno') diff --git a/pyuno/source/module/pyuno_impl.hxx b/pyuno/source/module/pyuno_impl.hxx index e48dae7ce9ac..9fda901886cb 100644 --- a/pyuno/source/module/pyuno_impl.hxx +++ b/pyuno/source/module/pyuno_impl.hxx @@ -80,14 +80,14 @@ bool isLog( RuntimeCargo const *cargo, sal_Int32 loglevel ); void log( RuntimeCargo *cargo, sal_Int32 level, std::u16string_view logString ); void log( RuntimeCargo *cargo, sal_Int32 level, const char *str ); void logCall( RuntimeCargo *cargo, const char *intro, - void * ptr, const OUString & aFunctionName, + void * ptr, std::u16string_view aFunctionName, const css::uno::Sequence< css::uno::Any > & args ); void logReply( RuntimeCargo *cargo, const char *intro, - void * ptr, const OUString & aFunctionName, + void * ptr, std::u16string_view aFunctionName, const css::uno::Any &returnValue, const css::uno::Sequence< css::uno::Any > & args ); void logException( RuntimeCargo *cargo, const char *intro, - void * ptr, const OUString &aFunctionName, + void * ptr, std::u16string_view aFunctionName, const void * data, const css::uno::Type & type ); const sal_Int32 VAL2STR_MODE_DEEP = 0; const sal_Int32 VAL2STR_MODE_SHALLOW = 1; diff --git a/pyuno/source/module/pyuno_util.cxx b/pyuno/source/module/pyuno_util.cxx index 35b96183c739..6023a4e310c6 100644 --- a/pyuno/source/module/pyuno_util.cxx +++ b/pyuno/source/module/pyuno_util.cxx @@ -143,7 +143,7 @@ void appendPointer(OUStringBuffer & buffer, void * pointer) { } void logException( RuntimeCargo *cargo, const char *intro, - void * ptr, const OUString &aFunctionName, + void * ptr, std::u16string_view aFunctionName, const void * data, const css::uno::Type & type ) { if( isLog( cargo, LogLevel::CALL ) ) @@ -151,7 +151,7 @@ void logException( RuntimeCargo *cargo, const char *intro, OUStringBuffer buf( 128 ); buf.appendAscii( intro ); appendPointer(buf, ptr); - buf.append( "]." + aFunctionName + " = " ); + buf.append( OUString::Concat("].") + aFunctionName + " = " ); buf.append( val2str( data, type.getTypeLibType(), VAL2STR_MODE_SHALLOW ) ); log( cargo,LogLevel::CALL, buf.makeStringAndClear() ); @@ -163,14 +163,14 @@ void logReply( RuntimeCargo *cargo, const char *intro, void * ptr, - const OUString & aFunctionName, + std::u16string_view aFunctionName, const Any &returnValue, const Sequence< Any > & aParams ) { OUStringBuffer buf( 128 ); buf.appendAscii( intro ); appendPointer(buf, ptr); - buf.append( "]." + aFunctionName + "()=" ); + buf.append( OUString::Concat("].") + aFunctionName + "()=" ); if( isLog( cargo, LogLevel::ARGS ) ) { buf.append( @@ -186,13 +186,13 @@ void logReply( } void logCall( RuntimeCargo *cargo, const char *intro, - void * ptr, const OUString & aFunctionName, + void * ptr, std::u16string_view aFunctionName, const Sequence< Any > & aParams ) { OUStringBuffer buf( 128 ); buf.appendAscii( intro ); appendPointer(buf, ptr); - buf.append( "]." + aFunctionName + "(" ); + buf.append( OUString::Concat("].") + aFunctionName + "(" ); if( isLog( cargo, LogLevel::ARGS ) ) { for( int i = 0; i < aParams.getLength() ; i ++ ) -- cgit