aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/ScintillaBase.cxx
diff options
context:
space:
mode:
authorNeil <nyamatongwe@gmail.com>2020-03-31 08:15:54 +1100
committerNeil <nyamatongwe@gmail.com>2020-03-31 08:15:54 +1100
commit91ecae0a4522b34ced2ac667d4efca0bdb449827 (patch)
tree9c370e0f5421522920f2d6738118d930c1cff3b0 /src/ScintillaBase.cxx
parent30748b957f1fbce6c79c7ac48e8b377cd6c7fd5a (diff)
downloadscintilla-mirror-91ecae0a4522b34ced2ac667d4efca0bdb449827.tar.gz
Pass argument as unique_ptr to show transfer of ownership. Add const and noexcept.
Diffstat (limited to 'src/ScintillaBase.cxx')
-rw-r--r--src/ScintillaBase.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ScintillaBase.cxx b/src/ScintillaBase.cxx
index 2098fcb6f..8e3a86c15 100644
--- a/src/ScintillaBase.cxx
+++ b/src/ScintillaBase.cxx
@@ -620,7 +620,7 @@ void LexState::SetInstance(ILexer5 *instance_) {
LexState *ScintillaBase::DocumentLexState() {
if (!pdoc->GetLexInterface()) {
- pdoc->SetLexInterface(new LexState(pdoc));
+ pdoc->SetLexInterface(std::make_unique<LexState>(pdoc));
}
return dynamic_cast<LexState *>(pdoc->GetLexInterface());
}