summaryrefslogtreecommitdiff
path: root/basctl
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2020-06-23 15:02:35 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2020-06-24 08:43:55 +0200
commita2fc883173d7053cefe543620982051ae40c4b03 (patch)
treedac1b760925c8151dfd8a9cbe3a8735b68ab9f79 /basctl
parent010713e65ccade7b682c219707c8db3d864145c1 (diff)
use more std::container::insert instead of std::copy
which is both more compact code, and more efficient, since the insert method can do smarter resizing Change-Id: I17f226660f87cdf002edccc29b4af8fd59a25f91 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/96948 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'basctl')
-rw-r--r--basctl/source/basicide/scriptdocument.cxx4
1 files changed, 1 insertions, 3 deletions
diff --git a/basctl/source/basicide/scriptdocument.cxx b/basctl/source/basicide/scriptdocument.cxx
index cedadda510cf..d557bd5f31f4 100644
--- a/basctl/source/basicide/scriptdocument.cxx
+++ b/basctl/source/basicide/scriptdocument.cxx
@@ -1228,9 +1228,7 @@ namespace basctl
OUString aBaseName = _eType == E_SCRIPTS ? OUString("Module") : OUString("Dialog");
Sequence< OUString > aUsedNames( getObjectNames( _eType, _rLibName ) );
- std::set< OUString > aUsedNamesCheck;
- std::copy( aUsedNames.begin(), aUsedNames.end(),
- std::insert_iterator< std::set< OUString > >( aUsedNamesCheck, aUsedNamesCheck.begin() ) );
+ std::set< OUString > aUsedNamesCheck( aUsedNames.begin(), aUsedNames.end() );
bool bValid = false;
sal_Int32 i = 1;