diff options
author | Neil <nyamatongwe@gmail.com> | 2018-03-01 09:55:25 +1100 |
---|---|---|
committer | Neil <nyamatongwe@gmail.com> | 2018-03-01 09:55:25 +1100 |
commit | 69f3505ba3066c23024dc6bb6878a339474581bf (patch) | |
tree | d1c11379b0b7bac940ba06c749a629703980c292 /src/ViewStyle.cxx | |
parent | 3ed7408fb4c322183249afc7f0fce3b9f5de1cf1 (diff) | |
download | scintilla-mirror-69f3505ba3066c23024dc6bb6878a339474581bf.tar.gz |
Use make_unique in preference to new.
From Effective Modern C++ Item 21.
Diffstat (limited to 'src/ViewStyle.cxx')
-rw-r--r-- | src/ViewStyle.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ViewStyle.cxx b/src/ViewStyle.cxx index d83505d40..1c4f6d690 100644 --- a/src/ViewStyle.cxx +++ b/src/ViewStyle.cxx @@ -586,7 +586,7 @@ void ViewStyle::CreateAndAddFont(const FontSpecification &fs) { if (fs.fontName) { FontMap::iterator it = fonts.find(fs); if (it == fonts.end()) { - fonts[fs] = std::unique_ptr<FontRealised>(new FontRealised()); + fonts[fs] = std::make_unique<FontRealised>(); } } } |