summaryrefslogtreecommitdiff
path: root/xmlhelp
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-08-10 16:43:55 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-08-11 12:38:32 +0200
commitd347c2403605c5aa3ddd98fb605366914acab79f (patch)
treee39624030741234c514bccd858e69d6318dfba68 /xmlhelp
parentf0e68d4feaaa43f7450432ad1ebd92c2b572400f (diff)
convert std::map::insert to std::map::emplace
which is considerably less verbose Change-Id: Ifa373e8eb09e39bd6c8d3578641610a6055a187b Reviewed-on: https://gerrit.libreoffice.org/40978 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'xmlhelp')
-rw-r--r--xmlhelp/source/cxxhelp/provider/databases.cxx10
1 files changed, 5 insertions, 5 deletions
diff --git a/xmlhelp/source/cxxhelp/provider/databases.cxx b/xmlhelp/source/cxxhelp/provider/databases.cxx
index 5f5300d839b9..6cfa804e4f02 100644
--- a/xmlhelp/source/cxxhelp/provider/databases.cxx
+++ b/xmlhelp/source/cxxhelp/provider/databases.cxx
@@ -342,7 +342,7 @@ StaticModuleInformation* Databases::getStaticInformationForModule( const OUStrin
OUString key = processLang(Language) + "/" + Module;
std::pair< ModInfoTable::iterator,bool > aPair =
- m_aModInfo.insert( ModInfoTable::value_type( key,nullptr ) );
+ m_aModInfo.emplace(key,nullptr);
ModInfoTable::iterator it = aPair.first;
@@ -471,7 +471,7 @@ helpdatafileproxy::Hdf* Databases::getHelpDataFile( const OUString& Database,
key = *pExtensionPath + Language + dbFileName; // make unique, don't change language
std::pair< DatabasesTable::iterator,bool > aPair =
- m_aDatabases.insert( DatabasesTable::value_type( key, reinterpret_cast<helpdatafileproxy::Hdf *>(0) ) );
+ m_aDatabases.emplace( key, reinterpret_cast<helpdatafileproxy::Hdf *>(0) );
DatabasesTable::iterator it = aPair.first;
@@ -510,7 +510,7 @@ Databases::getCollator( const OUString& Language )
osl::MutexGuard aGuard( m_aMutex );
CollatorTable::iterator it =
- m_aCollatorTable.insert( CollatorTable::value_type( key, Reference< XCollator >() ) ).first;
+ m_aCollatorTable.emplace( key, Reference< XCollator >() ).first;
if( ! it->second.is() )
{
@@ -725,7 +725,7 @@ KeywordInfo* Databases::getKeyword( const OUString& Database,
OUString key = processLang(Language) + "/" + Database;
std::pair< KeywordInfoTable::iterator,bool > aPair =
- m_aKeywordInfo.insert( KeywordInfoTable::value_type( key,nullptr ) );
+ m_aKeywordInfo.emplace( key,nullptr );
KeywordInfoTable::iterator it = aPair.first;
@@ -805,7 +805,7 @@ Reference< XHierarchicalNameAccess > Databases::jarFile( const OUString& jar,
osl::MutexGuard aGuard( m_aMutex );
ZipFileTable::iterator it =
- m_aZipFileTable.insert( ZipFileTable::value_type( key,Reference< XHierarchicalNameAccess >(nullptr) ) ).first;
+ m_aZipFileTable.emplace( key,Reference< XHierarchicalNameAccess >(nullptr) ).first;
if( ! it->second.is() )
{