diff options
| author | mitchell <unknown> | 2020-01-05 21:22:02 -0500 |
|---|---|---|
| committer | mitchell <unknown> | 2020-01-05 21:22:02 -0500 |
| commit | 60e87889d6438e386acf58c3967fb874af9aae82 (patch) | |
| tree | 9c5c2660c59aff04ddedea19fa03fd271f8bba5c /src/EditView.cxx | |
| parent | dbb7374c185718655dd77c294eb281e8b93c538e (diff) | |
| download | scintilla-mirror-60e87889d6438e386acf58c3967fb874af9aae82.tar.gz | |
Added Sci::make_unique() and Sci::size() for better compatibility with the default branch.
std::make_unique() is c++14 and std::size() is c++17.
Diffstat (limited to 'src/EditView.cxx')
| -rw-r--r-- | src/EditView.cxx | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/EditView.cxx b/src/EditView.cxx index c16f25ac6..3ae7a5d67 100644 --- a/src/EditView.cxx +++ b/src/EditView.cxx @@ -28,7 +28,6 @@ #include "ILexer.h" #include "Scintilla.h" -#include "StringCopy.h" #include "CharacterSet.h" #include "CharacterCategory.h" #include "Position.h" @@ -229,7 +228,7 @@ bool EditView::ClearTabstops(Sci::Line line) { bool EditView::AddTabstop(Sci::Line line, int x) { if (!ldTabstops) { - ldTabstops.reset(new LineTabstops()); + ldTabstops = Sci::make_unique<LineTabstops>(); } return ldTabstops && ldTabstops->AddTabstop(line, x); } @@ -287,7 +286,7 @@ static const char *ControlCharacterString(unsigned char ch) noexcept { "DLE", "DC1", "DC2", "DC3", "DC4", "NAK", "SYN", "ETB", "CAN", "EM", "SUB", "ESC", "FS", "GS", "RS", "US" }; - if (ch < ELEMENTS(reps)) { + if (ch < Sci::size(reps)) { return reps[ch]; } else { return "BAD"; |
