summaryrefslogtreecommitdiffstats
path: root/src/gui/text/qtextdocument_p.h
diff options
context:
space:
mode:
authorMarc Mutz <marc.mutz@qt.io>2022-12-26 22:46:41 +0100
committerMarc Mutz <marc.mutz@qt.io>2022-12-27 11:29:24 +0100
commit436501d87754ed61bc2d9f574b97be84c30a3f05 (patch)
tree10039ba1c6e6185c261104ecf149a2c25936728a /src/gui/text/qtextdocument_p.h
parente5a7487c626be83b1f7549773333f1729771563f (diff)
QTextDocumentPrivate: de-inline {add,remove}Cursor()
In a 'ninja qtdeclarative' build, the addCursor() function alone is compiled 458x for a total of almost 10s cumulative compilation time. This makes it one of the top-20 template instantiations in a Clang -ftime-trace build. The removeCursor() function doesn't show up quite as much, but de-inline, too, while we're at it. Pick-to: 6.5 Task-number: QTBUG-97601 Change-Id: I37b920a8b364861efab78f736d71642dc82d8982 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/gui/text/qtextdocument_p.h')
-rw-r--r--src/gui/text/qtextdocument_p.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gui/text/qtextdocument_p.h b/src/gui/text/qtextdocument_p.h
index effcfcabed..d77ee7420b 100644
--- a/src/gui/text/qtextdocument_p.h
+++ b/src/gui/text/qtextdocument_p.h
@@ -243,8 +243,8 @@ private:
public:
void documentChange(int from, int length);
- inline void addCursor(QTextCursorPrivate *c) { cursors.insert(c); }
- inline void removeCursor(QTextCursorPrivate *c) { cursors.remove(c); }
+ void addCursor(QTextCursorPrivate *c);
+ void removeCursor(QTextCursorPrivate *c);
QTextFrame *frameAt(int pos) const;
QTextFrame *rootFrame() const;