From c2393df02332618c8cf6159d9d6f6a40041ced89 Mon Sep 17 00:00:00 2001 From: Erik Verbruggen Date: Fri, 4 Jun 2010 09:36:05 +0200 Subject: Introduced a token cache for the C++ editor. This should speed things up a bit, because before, the line was tokenized at least 3 times. --- src/plugins/cpptools/cpptoolseditorsupport.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/plugins/cpptools/cpptoolseditorsupport.h') diff --git a/src/plugins/cpptools/cpptoolseditorsupport.h b/src/plugins/cpptools/cpptoolseditorsupport.h index 882a9ac9aa..61fed38d3c 100644 --- a/src/plugins/cpptools/cpptoolseditorsupport.h +++ b/src/plugins/cpptools/cpptoolseditorsupport.h @@ -36,6 +36,7 @@ #include #include #include +#include QT_BEGIN_NAMESPACE class QTimer; @@ -72,6 +73,8 @@ public: QString contents(); unsigned editorRevision() const; + CPlusPlus::TokenCache *tokenCache(); + Q_SIGNALS: void contentsChanged(); @@ -89,6 +92,7 @@ private: QFuture _documentParser; QString _cachedContents; unsigned _revision; + CPlusPlus::TokenCache _tokenCache; }; } // namespace Internal -- cgit v1.2.1