diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-05-09 12:14:32 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-05-09 13:52:30 +0200 |
commit | 12191a4f30078bb81c39a74a994ba7b2b410adaf (patch) | |
tree | 394626ae75e6b77e4159657847f894e4f7c9495b /basic/source | |
parent | 3a9854a92923df8013ca832c48aa9f284bcb1adc (diff) |
make loplugin constantparam smarter about string params
Change-Id: Id3df69b38fd35f46735246a6d307a89aa10d4294
Reviewed-on: https://gerrit.libreoffice.org/37426
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'basic/source')
-rw-r--r-- | basic/source/classes/sb.cxx | 4 | ||||
-rw-r--r-- | basic/source/classes/sbxmod.cxx | 8 | ||||
-rw-r--r-- | basic/source/inc/sbjsmeth.hxx | 2 | ||||
-rw-r--r-- | basic/source/inc/sbjsmod.hxx | 2 | ||||
-rw-r--r-- | basic/source/sbx/sbxbase.cxx | 2 | ||||
-rw-r--r-- | basic/source/sbx/sbxcoll.cxx | 5 |
6 files changed, 11 insertions, 12 deletions
diff --git a/basic/source/classes/sb.cxx b/basic/source/classes/sb.cxx index ac8bf7f56d87..c3e0a63c2668 100644 --- a/basic/source/classes/sb.cxx +++ b/basic/source/classes/sb.cxx @@ -425,9 +425,9 @@ SbxBase* SbiFactory::Create( sal_uInt16 nSbxId, sal_uInt32 nCreator ) case SBXID_BASICMETHOD: return new SbMethod( "", SbxVARIANT, nullptr ); case SBXID_JSCRIPTMOD: - return new SbJScriptModule( "" ); + return new SbJScriptModule; case SBXID_JSCRIPTMETH: - return new SbJScriptMethod( "", SbxVARIANT ); + return new SbJScriptMethod( SbxVARIANT ); } } return nullptr; diff --git a/basic/source/classes/sbxmod.cxx b/basic/source/classes/sbxmod.cxx index 50b435c7c80a..aca923d8c7d5 100644 --- a/basic/source/classes/sbxmod.cxx +++ b/basic/source/classes/sbxmod.cxx @@ -1913,8 +1913,8 @@ void SbModule::handleProcedureProperties( SfxBroadcaster& rBC, const SfxHint& rH // Implementation SbJScriptModule (Basic module for JavaScript source code) -SbJScriptModule::SbJScriptModule( const OUString& rName ) - :SbModule( rName ) +SbJScriptModule::SbJScriptModule() + :SbModule( "" ) { } @@ -2135,8 +2135,8 @@ void SbMethod::Broadcast( SfxHintId nHintId ) // Implementation of SbJScriptMethod (method class as a wrapper for JavaScript-functions) -SbJScriptMethod::SbJScriptMethod( const OUString& r, SbxDataType t ) - : SbMethod( r, t, nullptr ) +SbJScriptMethod::SbJScriptMethod( SbxDataType t ) + : SbMethod( "", t, nullptr ) { } diff --git a/basic/source/inc/sbjsmeth.hxx b/basic/source/inc/sbjsmeth.hxx index 3403b392986d..2e4abc509bed 100644 --- a/basic/source/inc/sbjsmeth.hxx +++ b/basic/source/inc/sbjsmeth.hxx @@ -30,7 +30,7 @@ class SbJScriptMethod : public SbMethod { public: - SbJScriptMethod( const OUString&, SbxDataType ); + SbJScriptMethod( SbxDataType ); virtual ~SbJScriptMethod() override; SBX_DECL_PERSIST_NODATA(SBXID_JSCRIPTMETH,2); diff --git a/basic/source/inc/sbjsmod.hxx b/basic/source/inc/sbjsmod.hxx index a29d5704d469..9d2d7d8f4194 100644 --- a/basic/source/inc/sbjsmod.hxx +++ b/basic/source/inc/sbjsmod.hxx @@ -32,7 +32,7 @@ class SbJScriptModule : public SbModule virtual bool StoreData( SvStream& ) const override; public: SBX_DECL_PERSIST_NODATA(SBXID_JSCRIPTMOD,1); - SbJScriptModule( const OUString& ); // hand through + SbJScriptModule(); // hand through }; #endif diff --git a/basic/source/sbx/sbxbase.cxx b/basic/source/sbx/sbxbase.cxx index 060b09101152..b165f3a8371d 100644 --- a/basic/source/sbx/sbxbase.cxx +++ b/basic/source/sbx/sbxbase.cxx @@ -157,7 +157,7 @@ SbxBase* SbxBase::Create( sal_uInt16 nSbxId, sal_uInt32 nCreator ) case SBXID_OBJECT: return new SbxObject( "" ); case SBXID_COLLECTION: return new SbxCollection( "" ); case SBXID_FIXCOLLECTION: - return new SbxStdCollection( "", "" ); + return new SbxStdCollection; case SBXID_METHOD: return new SbxMethod( "", SbxEMPTY ); case SBXID_PROPERTY: return new SbxProperty( "", SbxEMPTY ); } diff --git a/basic/source/sbx/sbxcoll.cxx b/basic/source/sbx/sbxcoll.cxx index 3fa3b690d19b..a624d0241cf7 100644 --- a/basic/source/sbx/sbxcoll.cxx +++ b/basic/source/sbx/sbxcoll.cxx @@ -237,9 +237,8 @@ bool SbxCollection::LoadData( SvStream& rStrm, sal_uInt16 nVer ) } -SbxStdCollection::SbxStdCollection - ( const OUString& rClass, const OUString& rElem ) - : SbxCollection( rClass ), aElemClass( rElem ), +SbxStdCollection::SbxStdCollection() + : SbxCollection( "" ), bAddRemoveOk( true ) {} |