From cb958bb5e0e81d343c91c08a8513006a7bf1d913 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Fri, 9 Sep 2016 11:06:42 +0200 Subject: loplugin:constantparam in sot..svl Change-Id: I08db2db3b90725c556e3ba062da5d62d98f6e882 Reviewed-on: https://gerrit.libreoffice.org/28769 Reviewed-by: Noel Grandin Tested-by: Noel Grandin --- stoc/source/corereflection/crefl.cxx | 4 +--- stoc/source/corereflection/lrucache.hxx | 6 +++--- 2 files changed, 4 insertions(+), 6 deletions(-) (limited to 'stoc/source') diff --git a/stoc/source/corereflection/crefl.cxx b/stoc/source/corereflection/crefl.cxx index 9275e453c40e..54a3a452faee 100644 --- a/stoc/source/corereflection/crefl.cxx +++ b/stoc/source/corereflection/crefl.cxx @@ -43,8 +43,6 @@ using namespace osl; namespace stoc_corefl { -static const sal_Int32 CACHE_SIZE = 256; - #define IMPLNAME "com.sun.star.comp.stoc.CoreReflection" static Sequence< OUString > core_getSupportedServiceNames() @@ -61,7 +59,7 @@ static OUString core_getImplementationName() IdlReflectionServiceImpl::IdlReflectionServiceImpl( const Reference< XComponentContext > & xContext ) : OComponentHelper( _aComponentMutex ) - , _aElements( CACHE_SIZE ) + , _aElements() { xContext->getValueByName( "/singletons/com.sun.star.reflection.theTypeDescriptionManager" ) >>= _xTDMgr; diff --git a/stoc/source/corereflection/lrucache.hxx b/stoc/source/corereflection/lrucache.hxx index 13f4803ca085..a36ba830e779 100644 --- a/stoc/source/corereflection/lrucache.hxx +++ b/stoc/source/corereflection/lrucache.hxx @@ -58,7 +58,7 @@ public:
@param nCachedElements number of elements to be cached; default param set to 128 */ - explicit inline LRU_Cache( sal_Int32 nCachedElements = 128 ); + explicit inline LRU_Cache(); /** Destructor: releases all cached elements and keys.
*/ @@ -84,11 +84,11 @@ public: }; template< class t_Key, class t_Val, class t_KeyHash > -inline LRU_Cache< t_Key, t_Val, t_KeyHash >::LRU_Cache( sal_Int32 nCachedElements ) +inline LRU_Cache< t_Key, t_Val, t_KeyHash >::LRU_Cache() #ifdef __CACHE_DIAGNOSE : _nCachedElements( 4 ) #else - : _nCachedElements( nCachedElements ) + : _nCachedElements( 256 ) #endif , _pBlock( nullptr ) , _pHead( nullptr ) -- cgit