- Aug 07, 2012
-
-
Christian Kamm authored
Task-number: QTCREATORBUG-7702 Change-Id: I0ec2e1eb9bf1c556b0a426d4405df1c48b5653ed Reviewed-by:
Leandro Melo <leandro.melo@nokia.com>
-
Christian Kamm authored
Task-number: QTCREATORBUG-7512 Change-Id: I59898a0449f1f6997963e0f31c47293358a773f6 Reviewed-by:
Leandro Melo <leandro.melo@nokia.com>
-
- Aug 06, 2012
-
-
hjk authored
More uniform. Change-Id: I1c6057981f4c2b3170a4e69f0674fe4caf1143a2 Reviewed-by:
Robert Loehning <robert.loehning@nokia.com>
-
- Jul 19, 2012
-
-
Eike Ziller authored
Change-Id: I7134d7de30bcf9f9dcfad42520dd45ee083a852d Reviewed-by:
Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
-
- Jun 28, 2012
-
-
Leandro Melo authored
The parser now understands emit/Q_EMIT as an expression statement. Also, the recent fixes in the preprocessor introduced a side-effect in the hanlding of code such as: emit signal(); Member signal started being treated as a local use (parsed as a declaration) and possibily being highlighted as unused variable. Previously that worked by accident since there was an inconsistency in the preprocessor on which only object-like macros were being expanded even when the "no expand" flag was set. Then, the code mentioned above was being parsed as an expression, what kind of worked. Change-Id: I47a68ed4c1c1702872620b8ed7c7264fb0997034 Reviewed-by:
Roberto Raggi <roberto.raggi@nokia.com>
-
- Jun 25, 2012
-
-
Leandro Melo authored
Summary of most relevant items: - Preprocessor output format change. No more gen true/false. Instead a more intuitive and natural expansion (like from a real compiler) is performed directly corresponding to the macro invocation. Notice that information about the generated tokens is not lost, because it's now embedded in the expansion section header (in terms of lines and columns as explained in the code). In addition the location on where the macro expansion happens is also documented for future use. - Fix line control directives and associated token line numbers. This was not detected in tests cases because some of them were actually wrong: Within expansions the line information was being considered as originally computed in the macro definition, while the desired and expected for Creator's reporting mechanism (just like regular compilers) is the line from the expanded version of the tokens. - Do not allow for eager expansion. This was previously being done inside define directives. However, it's not allowed and might lead to incorrect results, since the argument substitution should only happen upon the macro invocation (and following nested ones). At least GCC and clang are consistent with that. See test case tst_Preprocessor:dont_eagerly_expand for a detailed explanation. - Revive the 'expanded' token flag. This is used to mark every token that originates from a macro expansion. Notice, however, that expanded tokens are not necessarily generated tokens (although every generated token is a expanded token). Expanded tokens that are not generated are those which are still considered by our code model features, since they are visible on the editor. The translation unit is smart enough to calculate line/column position for such tokens based on the information from the expansion section header. - How expansions are tracked has also changed. Now, we simply add two surrounding marker tokens to each "top-level" expansion sequence. There is an enumeration that control expansion states. Also, no "previous" token is kept around. - Preprocessor client methods suffered a change in signature so they now receive the line number of the action in question as a paramater. Previously such line could be retrieved by the client implementation by accessing the environment line. However, this is not reliable because we try to avoid synchronization of the output/environment lines in order to avoid unnecessary output, while expanding macros or handling preprocessor directives. - Although macros are not expanded during define directives (as mentioned above) the preprocessor client is now "notified" when it sees a macro. This is to allow usage tracking. - Other small stuff. This is all in one patch because the fixes are a consequence of the change in preprocessing control. Change-Id: I8f4c6e6366f37756ec65d0a93b79f72a3ac4ed50 Reviewed-by:
Roberto Raggi <roberto.raggi@nokia.com>
-
- Jun 19, 2012
-
-
Leandro Melo authored
Do not expand function-like macros at all when there's a mismatch in the parameter/argument count. The report below raises the issue but its expected result is not correct. This would be the more appropriate fix. Task-number: QTCREATORBUG-7225 Change-Id: Ide8580faa7b724d3e8b396ec1f899cc5ca7f9e7e Reviewed-by:
hjk <qthjk@ovi.com>
-
- Jun 12, 2012
-
-
Leandro Melo authored
Change-Id: I6d226b4e42f94ebee41d012050c5109895f0c432 Reviewed-by:
hjk <qthjk@ovi.com>
-
- Jun 05, 2012
-
-
Leandro Melo authored
It was previously beeing skipped. Change-Id: Iadd9b03acbcf0ee0fb4db537b8597661cb93af3f Reviewed-by:
hjk <qthjk@ovi.com>
-
- Jun 01, 2012
-
-
Leandro Melo authored
Make sure the environment line is consistent during preprocessor directives and identifier handling so clients can rely on consistent information. Particularly important for macro usages. New tests also added. Change-Id: I962a39a86cd17b8d945d2959c2c95e2d258ea3e6 Reviewed-by:
hjk <qthjk@ovi.com>
-
- May 30, 2012
-
-
hjk authored
An missing closing parantheses after "defined(..." caused an endless loop. Change-Id: I19b17cebc1a56880216c3bfb67c9d296f80cc064 Reviewed-by:
Leandro Melo <leandro.melo@nokia.com>
-
- May 23, 2012
-
-
Leandro Melo authored
Due to latest changes the macro arguments were no longer being tracked. Then they were no available in the document's macro uses. The patch also makes sure that the preprocessor condition to be expanded is spelled exactly as in the source code (this guarantees that offsets will be properly calculated). Change-Id: I8aff0c3aca0c528ef2c4bcfa56ff1c3da2961060 Reviewed-by:
Roberto Raggi <roberto.raggi@nokia.com>
-
Thiago Macieira authored
They're non-standard. Remove them. Change-Id: I58dc093c2459747ce0183685d325522fb51e86ab Reviewed-by:
Kai Koehne <kai.koehne@nokia.com>
-
- May 01, 2012
-
-
hjk authored
Change-Id: Ibca5737ad906c1db7e1bf4e15e5c92030e87c0bb Reviewed-by:
Thomas Hartmann <Thomas.Hartmann@nokia.com>
-
- Apr 25, 2012
-
-
hjk authored
Task-number: QTCREATORBUG-7256 Change-Id: I6149e56e5f50f75c9e039be9c162036a3890e2d7 Reviewed-by:
David Schulz <david.schulz@nokia.com> Reviewed-by:
hjk <qthjk@ovi.com>
-
- Apr 23, 2012
-
-
Erik Verbruggen authored
Generated tokens do not have a position in any source file, so not try to indent them. Previously, the 'source' used was the scratch buffer, which would not contain newlines, so the indent depth would be the length of the scratch buffer at that point. Task-number: QTCREATORBUG-7262 Change-Id: If94213d6dffd13dd2b47c7038ec2398ad925d904 Reviewed-by:
Yuchen Deng <loaden@gmail.com> Reviewed-by:
Thomas Hartmann <Thomas.Hartmann@nokia.com>
-
- Apr 22, 2012
-
-
Erik Verbruggen authored
Change-Id: Ib2ba453e98befceaf3445a2daa6ecc4660a6a9b4 Reviewed-by:
Erik Verbruggen <erik.verbruggen@nokia.com>
-
- Apr 19, 2012
-
-
hjk authored
Easier to follow. Change-Id: I6da1ca862ddb7048a6d16bf5e6ea18d6b2cfc7f8 Reviewed-by:
hjk <qthjk@ovi.com>
-
hjk authored
Change-Id: I3b06cfc827543d20069f69e00123ccf2bc19ed31 Reviewed-by:
hjk <qthjk@ovi.com>
-
hjk authored
Change-Id: I39cfbd7f7adf13ec52527c79c9481d56283087df Reviewed-by:
hjk <qthjk@ovi.com>
-
hjk authored
Change-Id: Icc3ee542c8e8f95dfd48604144e3f4ab638fdcd4 Reviewed-by:
hjk <qthjk@ovi.com>
-
hjk authored
Change-Id: Id53c5ebc2867c1ea1e62bb9be6eebe9732774713 Reviewed-by:
Thomas Hartmann <Thomas.Hartmann@nokia.com>
-
hjk authored
Change-Id: I12e487d278621325bfc3add4c569297efe3c264b Reviewed-by:
hjk <qthjk@ovi.com>
-
hjk authored
Change-Id: I56b1ee492469c523266337a885f664dea5deab98 Reviewed-by:
hjk <qthjk@ovi.com>
-
hjk authored
Change-Id: Idb93d359bd45696a38cb863dcea30c5c377eeabb Reviewed-by:
hjk <qthjk@ovi.com>
-
hjk authored
Change-Id: I339696763b045ef1bda17dd55746738ef4ddbb67 Reviewed-by:
hjk <qthjk@ovi.com>
-
hjk authored
Change-Id: I92ffe360847fc828b23467d0639824aea63fab32 Reviewed-by:
Thomas Hartmann <Thomas.Hartmann@nokia.com>
-
- Apr 18, 2012
-
-
hjk authored
It destroys preallocation. See https://bugreports.qt-project.org/browse/QTBUG-25371 . Change-Id: Idde09a07f250a347f8016d8fdb04cd00d031fe10 Reviewed-by:
Thomas Hartmann <Thomas.Hartmann@nokia.com>
-
hjk authored
Change-Id: I58de7e704bdbd3861a4a534d8080cc2a8399b7eb Reviewed-by:
Thomas Hartmann <Thomas.Hartmann@nokia.com>
-
hjk authored
Change-Id: I1c45bb9a5118e19b15878eb04e65b52bd6c5d1e7 Reviewed-by:
Thomas Hartmann <Thomas.Hartmann@nokia.com>
-
hjk authored
Change-Id: Ic86d8b091da332393a527ba634a23556f2001a8b Reviewed-by:
Thomas Hartmann <Thomas.Hartmann@nokia.com>
-
- Apr 11, 2012
-
-
Thiago Macieira authored
std::list is in #include <list> /home/thiago/src/qt/creator/src/libs/cplusplus/pp-engine.cpp(110): error: qualified name is not allowed std::list<PPToken> tokens; ^ Change-Id: I02a08afe6a678d66d528ce5dfca08317735704e8 Reviewed-by:
Roberto Raggi <roberto.raggi@nokia.com>
-
- Apr 02, 2012
-
-
Francois Ferrand authored
The line corresponding to the macro definition is simply the token's line. This caused errors in the macro definitions, since there were multiple macros defined on the same line of the same file. Task-number: QTCREATORBUG-7217 Change-Id: I56d17eeba677ac51f9eed283c0e964019bdfe4b7 Reviewed-by:
Roberto Raggi <roberto.raggi@nokia.com>
-
Francois Ferrand authored
- Notify end of macro if function expansion is skipped. - Do not notify client of generated macros expansion. Change-Id: Ic027fc13ee391425a5ebadc8e84b9305912dbcf0 Reviewed-by:
Roberto Raggi <roberto.raggi@nokia.com>
-
- Mar 30, 2012
-
-
Erik Verbruggen authored
Change-Id: I11f6cff556519b768dd5d979dfd184809ed18291 Reviewed-by:
Roberto Raggi <roberto.raggi@nokia.com>
-
Erik Verbruggen authored
Change-Id: Ia54c5ddc801962c89dc0483f5912f1de436b8f43 Reviewed-by:
Erik Verbruggen <erik.verbruggen@nokia.com>
-
Erik Verbruggen authored
Change-Id: I60d25109ae8fe3628b1899078a21010263787c33 Reviewed-by:
Roberto Raggi <roberto.raggi@nokia.com>
-
- Mar 29, 2012
-
-
Erik Verbruggen authored
Change-Id: Id1c4046d028ad26d17b28feb53a832f3b48363f1 Reviewed-by:
Erik Verbruggen <erik.verbruggen@nokia.com>
-
Erik Verbruggen authored
This rewrite fixes a couple of issues with the pre-processor. It now supports: - macros in macro bodies - stringification of parameters [cpp.stringize] - the concatenation operator [cpp.concat] - #include MACRO_HERE - defined() inside macro bodies used in pp-conditions. Change-Id: Ifdb78041fb6afadf44f939a4bd66ce2832b8601f Reviewed-by:
Roberto Raggi <roberto.raggi@nokia.com>
-
- Mar 19, 2012
-
-
Francois Ferrand authored
The macro used to be at the same line as the first token after the closing parenthesis. Change-Id: I4c2d7317632baf612900e84572017aeb247d0585 Reviewed-by:
Erik Verbruggen <erik.verbruggen@nokia.com>
-