diff options
author | Neil <nyamatongwe@gmail.com> | 2022-05-01 14:31:17 +1000 |
---|---|---|
committer | Neil <nyamatongwe@gmail.com> | 2022-05-01 14:31:17 +1000 |
commit | 4e556e4aaba49f4307ab4933a376e0c34d0be674 (patch) | |
tree | 9b708589b2163edc5ff26fd2c5f3a2a95dbad335 /src/PerLine.cxx | |
parent | 528eca1cf29f8e02afd3cb51724c2fe2eed69894 (diff) | |
download | scintilla-mirror-4e556e4aaba49f4307ab4933a376e0c34d0be674.tar.gz |
Optimize case where there are no annotations
Diffstat (limited to 'src/PerLine.cxx')
-rw-r--r-- | src/PerLine.cxx | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/PerLine.cxx b/src/PerLine.cxx index 762891ee3..2ea3f0ce4 100644 --- a/src/PerLine.cxx +++ b/src/PerLine.cxx @@ -357,6 +357,10 @@ std::unique_ptr<char[]>AllocateAnnotation(size_t length, int style) { LineAnnotation::~LineAnnotation() { } +bool LineAnnotation::Empty() const noexcept { + return annotations.Length() == 0; +} + void LineAnnotation::Init() { ClearAll(); } |