[LyX/master] Fix expensive thinko: operator++ returns a reference, not a copy
Jean-Marc Lasgouttes
lasgouttes at lyx.org
Mon Nov 7 22:19:45 UTC 2022
commit ec151de2cc530a9118517ac9299e30c17cb62255
Author: Jean-Marc Lasgouttes <lasgouttes at lyx.org>
Date: Tue Nov 8 00:06:18 2022 +0100
Fix expensive thinko: operator++ returns a reference, not a copy
This accounts for 45% of the row breaking time on the (huge) paragraph
of the MWE in bug #12598.
Fixes part of bug #12598.
---
src/TextMetrics.cpp | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/src/TextMetrics.cpp b/src/TextMetrics.cpp
index 00fb217..f58efa7 100644
--- a/src/TextMetrics.cpp
+++ b/src/TextMetrics.cpp
@@ -979,7 +979,7 @@ class flexible_const_iterator {
public:
//
- flexible_const_iterator operator++() {
+ flexible_const_iterator & operator++() {
if (pile_.empty())
++cit_;
else
More information about the lyx-cvs
mailing list