diff options
| author | Erik Verbruggen <[email protected]> | 2012-10-11 16:16:01 +0200 |
|---|---|---|
| committer | Erik Verbruggen <[email protected]> | 2012-10-15 10:58:07 +0200 |
| commit | f3faef5a1e345b02dfca0b8c682e5e36e318849f (patch) | |
| tree | 747ecc0a7a6b9d574ceff130767f386ee80b4a76 /src/libs/cplusplus/Macro.h | |
| parent | 199b243bca769049095b72bf5af7e95add1ecff6 (diff) | |
C++: Fix outdated macro usage info in documents.
Record revisions of documents in macro definitions and usages. Then,
when searching for usages, check the revision of the documents against
the revision of the macros. If they are out-of-sync, repreprocess the
documents to get up-to-date info.
Task-number: QTCREATORBUG-7872
Change-Id: I846bb52ec660024728ab117a9fb7e43382a50e63
Reviewed-by: Christian Stenger <[email protected]>
Diffstat (limited to 'src/libs/cplusplus/Macro.h')
| -rw-r--r-- | src/libs/cplusplus/Macro.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/libs/cplusplus/Macro.h b/src/libs/cplusplus/Macro.h index 80b797cbc77..241b15d69d3 100644 --- a/src/libs/cplusplus/Macro.h +++ b/src/libs/cplusplus/Macro.h @@ -95,6 +95,12 @@ public: void setFileName(const QString &fileName) { _fileName = fileName; } + unsigned fileRevision() const + { return _fileRevision; } + + void setFileRevision(unsigned fileRevision) + { _fileRevision = fileRevision; } + unsigned line() const { return _line; } @@ -154,6 +160,7 @@ private: QVector<PPToken> _definitionTokens; QVector<QByteArray> _formals; QString _fileName; + unsigned _fileRevision; unsigned _line; unsigned _offset; unsigned _length; |
