diff options
Diffstat (limited to 'svl/source/items/stylepool.cxx')
-rw-r--r-- | svl/source/items/stylepool.cxx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/svl/source/items/stylepool.cxx b/svl/source/items/stylepool.cxx index ea3efeaeb5f0..c241e61e85a1 100644 --- a/svl/source/items/stylepool.cxx +++ b/svl/source/items/stylepool.cxx @@ -24,6 +24,7 @@ #include <algorithm> #include <map> #include <memory> +#include <optional> #include <vector> namespace { @@ -385,10 +386,10 @@ std::shared_ptr<SfxItemSet> StylePoolImpl::insertItemSet( const SfxItemSet& rSet // Every SfxPoolItem in the SfxItemSet causes a step deeper into the tree, // a complete empty SfxItemSet would stay at the root node. // #i86923# insert ignorable items to the tree leaves. - std::unique_ptr<SfxItemSet> xFoundIgnorableItems; + std::optional<SfxItemSet> xFoundIgnorableItems; if ( mpIgnorableItems ) { - xFoundIgnorableItems.reset( new SfxItemSet( *mpIgnorableItems ) ); + xFoundIgnorableItems.emplace( *mpIgnorableItems ); } while( pItem ) { |