From 070f6e7b5fccfb11d27a86601f3f4ed086cc48b3 Mon Sep 17 00:00:00 2001 From: Neil Date: Wed, 5 May 2021 15:13:51 +1000 Subject: Avoid some warnings in ResetLineEnds. --- src/CellBuffer.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/CellBuffer.cxx') diff --git a/src/CellBuffer.cxx b/src/CellBuffer.cxx index 767a0c30d..6d760cdb5 100644 --- a/src/CellBuffer.cxx +++ b/src/CellBuffer.cxx @@ -887,11 +887,11 @@ void CellBuffer::ResetLineEnds() { // Reinitialize line data -- too much work to preserve plv->Init(); - const Sci::Position position = 0; + constexpr Sci::Position position = 0; const Sci::Position length = Length(); + plv->InsertText(0, length); Sci::Line lineInsert = 1; - const bool atLineStart = true; - plv->InsertText(lineInsert-1, length); + constexpr bool atLineStart = true; unsigned char chBeforePrev = 0; unsigned char chPrev = 0; for (Sci::Position i = 0; i < length; i++) { -- cgit v1.2.3