hjk
6d393252c4
preprocessor: rename operator() into run.
...
Easier to follow.
Change-Id: I6da1ca862ddb7048a6d16bf5e6ea18d6b2cfc7f8
Reviewed-by: hjk <qthjk@ovi.com >
2012-04-19 19:37:14 +02:00
hjk
538901d441
preprocessor: make Preprocessor::preprocess private
...
Change-Id: Ic81e3ebec1b42ae0698a340ee7e1c711225c1162
Reviewed-by: hjk <qthjk@ovi.com >
2012-04-19 18:47:03 +02:00
hjk
acf6f8f0cb
preprocessor: make Environment::{resolve,remove} work on ByteArrayRefs only
...
Change-Id: Idb93d359bd45696a38cb863dcea30c5c377eeabb
Reviewed-by: hjk <qthjk@ovi.com >
2012-04-19 18:41:18 +02:00
hjk
3428240233
preprocessor: add autotest for defined(...) and undefined(...)
...
Change-Id: I7c843a449bb6db348ab374b4bd2c378b797b94cd
Reviewed-by: hjk <qthjk@ovi.com >
2012-04-19 18:38:00 +02:00
hjk
37e3853090
preprocessor tests: compile fix
...
Change-Id: Iab9fb8ecbad94e08d39b6fad60caaf98a85d5980
Reviewed-by: hjk <qthjk@ovi.com >
2012-04-17 09:40:34 +02:00
Francois Ferrand
68471c2100
Preprocessor: fix macro definition line.
...
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 >
2012-04-02 17:01:52 +02:00
Francois Ferrand
1a10bcdaad
Add test case to preprocessor.
...
- This enables some tests which had been unexpectedly disabled in
earlier test.
- Tests to show issue QTCREATORBUG-7225.
- Tests which validates somehow behavior of preprocessor for
QTCREATORBUG-7217: the test passes, so the problem is likely not in the
startExpandingMacro() notification.
Change-Id: Ib7c1433e4dcdd8c1d19fa117371f94c1645ec3fb
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com >
2012-04-02 15:16:25 +02:00
Francois Ferrand
332072019a
Preprocessor: Fix client notification.
...
- 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 >
2012-04-02 13:49:00 +02:00
Erik Verbruggen
ff0a465403
[C++] Always output a #line as first line of the pp output.
...
Change-Id: I60d25109ae8fe3628b1899078a21010263787c33
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com >
2012-03-30 13:24:36 +02:00
Erik Verbruggen
2a74097b54
Fix #include MACRO_NAME.
...
Change-Id: Id1c4046d028ad26d17b28feb53a832f3b48363f1
Reviewed-by: Erik Verbruggen <erik.verbruggen@nokia.com >
2012-03-29 17:17:00 +02:00
Erik Verbruggen
60db573660
[C++] Rewrite of the preprocessor.
...
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 >
2012-03-29 14:28:17 +02:00
Eike Ziller
8f6d915948
Merge remote-tracking branch 'origin/2.5'
2012-03-28 16:31:29 +02:00
Erik Verbruggen
275e207d26
Fix invalid decltype error recovery which resulted in crashes.
...
Task-number: QTCREATORBUG-7174
Change-Id: I653db71adc45586cd8518ffd96118425fd3763be
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com >
2012-03-28 13:41:48 +02:00
Eike Ziller
7931159c09
Merge remote-tracking branch 'origin/2.5'
...
Conflicts:
src/libs/qmljsdebugclient/qmlprofilereventlist.cpp
src/libs/zeroconf/servicebrowser.cpp
src/plugins/qmlprofiler/qml/MainView.qml
src/plugins/qmlprofiler/qmlprofilerengine.cpp
src/plugins/qmlprofiler/qmlprofilertool.cpp
src/plugins/qmlprofiler/qmlprofilertraceview.h
src/plugins/qmlprofiler/tracewindow.cpp
Change-Id: Ib5e7579efffe74f2bf6871690d1e398e1062f986
2012-03-21 09:57:56 +01:00
Erik Verbruggen
19f1f6ca79
Added test for lambda function definitions.
...
Change-Id: I2233aa98a07e9c23463d4bec0b09dcccb89deb58
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com >
2012-03-20 14:28:51 +01:00
Francois Ferrand
2386d701b6
Preprocessor: fix line for generated code.
...
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 >
2012-03-19 10:48:43 +01:00
Francois Ferrand
558b6e08ae
Preprocessor: fix expanding macro arguments.
...
Expanding macro arguments can add or remove argument for a nested macro,
so the actual parameters list was not correct.
Also, remove unused arguments reference list and reserve space for the
expected number of arguments.
Change-Id: I4cf369cbb3909927c6bf65750bd715fa6f070fad
Reviewed-by: Erik Verbruggen <erik.verbruggen@nokia.com >
2012-03-19 10:35:21 +01:00
Francois Ferrand
3e9105e401
Preprocessor: fix handling of first empty argument.
...
First empty argument used to be dropped: e.g. MACRO(,test) would be
expanded with one parameter only, with value 'test'.
Change-Id: I693fbb7faf1360f62266fa04c4b39c2de0d159a7
Reviewed-by: Erik Verbruggen <erik.verbruggen@nokia.com >
2012-03-19 10:33:14 +01:00
Francois Ferrand
ffd58c577a
Preprocessor: Handle variadic arguments (__VA_ARGS__).
...
Change-Id: I69aa6c5e01ea97a4413f77f20ebbb4d4beb971aa
Reviewed-by: Erik Verbruggen <erik.verbruggen@nokia.com >
2012-03-19 10:31:09 +01:00
Erik Verbruggen
3a231e734c
Cleanup testcase.
...
Change-Id: I3db86fa5df4a2747f4c24e0414279dab59098c54
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com >
2012-03-13 12:00:43 +01:00
Erik Verbruggen
a621c99a0f
[C++] Add error recovery for namespace declarations.
...
Change-Id: I884ff9901c95467524e5eba38e91f75992d30e14
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com >
Reviewed-by: Flex Ferrum <flexferrum@gmail.com >
2012-02-28 10:22:31 +01:00
Erik Verbruggen
368d5926ca
C++: handle destructor names with template parameters.
...
Change-Id: I74b4fd5e043db935abc18345b303d294b71e8fc2
Reviewed-by: Tobias Hunger <tobias.hunger@nokia.com >
Reviewed-by: Erik Verbruggen <erik.verbruggen@nokia.com >
2012-02-23 08:39:34 +01:00
Erik Verbruggen
3fa55b7ab9
Removed module names from #include directives.
...
Getting the #include directives ready for Qt5. This includes the
new-project wizards.
Change-Id: Ia9261f1e8faec06b9285b694d2b7e9a095978d2b
Reviewed-by: Eike Ziller <eike.ziller@nokia.com >
2012-02-15 16:24:46 +01:00
Erik Verbruggen
d679dc4d53
C++: Added tests for C++11 features.
...
Change-Id: Ifa0bc37916d3ac3a523580bec15a6685709e7810
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com >
2012-02-10 08:30:48 +01:00
Roberto Raggi
5fb624b1db
Fix semantic of C++ 11 inline namespaces.
...
Add the declaring `inline' namespace to the `using list' of its
enclosing namespace symbol. This should be enough to ensure
the correct visibility of the symbols declarated in the inlined
namespace.
Change-Id: Id4de74577c498fe439a49709a306ef0deb145988
Reviewed-by: Leandro Melo <leandro.melo@nokia.com >
2012-02-03 15:37:17 +01:00
David Schulz
6d85b53f9c
Revert "Editor: Highlight background for whitespaces in strings and comments"
...
The change brokes the Lexer.
This reverts commit e46a5579d3
.
Change-Id: I3363c6eff74b53a7f2d9f417941cde07aaa92619
Reviewed-by: Leandro Melo <leandro.melo@nokia.com >
2012-02-03 11:52:01 +01:00
David Schulz
e46a5579d3
Editor: Highlight background for whitespaces in strings and comments
...
The whitespaces are now highlighted with the same backgroundcolor as the characters.
Also added a test for the Lexer.
Task-number: QTCREATORBUG-5802
Change-Id: Ic1bcd8cfe30d6b8a0281b7963eaab310f972b9d2
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com >
2012-02-01 11:17:56 +01:00
hjk
2931a499e6
Long live the king!
...
Change-Id: I2b72b34c0cfeafc8bdbaf49b83ff723544f2b6e2
Reviewed-by: Daniel Teske <daniel.teske@nokia.com >
2012-01-26 19:55:36 +01:00
Leandro Melo
c287d90604
C++: Rename source/setSource to utf8Source/setUtf8Source
...
Continuinng a previous commit... This is in order to make
the interface clearer.
Change-Id: Ic1b05217f878578bc84a064927507b75981c47d6
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com >
2012-01-13 11:22:28 +01:00
Christian Kamm
0ba1234108
C++ indenter: Improve member initializer indent.
...
If you indent the first initializer differently, that will now stick
for the following ones.
Change-Id: Ib08dfbf64282eda41202528b7255e693c350f7c6
Reviewed-by: Leandro Melo <leandro.melo@nokia.com >
2011-12-08 13:55:16 +01:00
Christian Kamm
bc1b724476
C++: Move codegen test into the CppTools plugin.
...
Change-Id: I4c70a9dbd5445188c3d202427da96e1c6ff90b63
Reviewed-by: Bill King <bill.king@nokia.com >
2011-11-15 15:37:29 +01:00
Eike Ziller
85cf2b661e
Merge remote-tracking branch 'origin/2.4'
...
Conflicts:
src/libs/qmljs/qmljsinterpreter.cpp
src/libs/qmljs/qmljsinterpreter.h
src/plugins/debugger/qml/scriptconsole.cpp
src/plugins/git/gitplugin.cpp
src/plugins/qmlprofiler/canvas/qdeclarativetiledcanvas.cpp
src/plugins/qmlprofiler/canvas/qdeclarativetiledcanvas_p.h
Change-Id: Iad59c8d87c72a21c79c047e374c0ab689998af39
2011-11-11 09:46:25 +01:00
hjk
31600758de
all: s/info@qt.nokia.com/qt-info@nokia.com/
...
Change-Id: If18afb5d4665924e7d9250dccbc60a65e6daa75e
Reviewed-by: Eike Ziller <eike.ziller@nokia.com >
2011-11-03 10:33:19 +01:00
Eike Ziller
81cce8902e
Merge remote-tracking branch 'origin/2.4'
...
Conflicts:
qtcreator.pri
src/libs/qmljs/qmljscheck.cpp
src/plugins/debugger/gdb/gdbengine.cpp
src/plugins/debugger/gdb/remotegdbserveradapter.cpp
src/plugins/plugins.pro
src/plugins/projectexplorer/buildmanager.cpp
src/plugins/qmldesigner/designercore/metainfo/nodemetainfo.cpp
Change-Id: Id2dcebf95b94dc46c1d85908ba1d1378aaf362ac
2011-10-28 10:17:44 +02:00
Christian Kamm
65ef5f7a35
Fix tests/auto/cplusplus/codegen on windows.
...
Change-Id: I765baa58c6b39d98949c0c8530623baf112f42bb
Reviewed-by: Bill King <bill.king@nokia.com >
2011-10-20 11:44:15 +02:00
Christian Kamm
aa3d406faf
C++ indenter: Accept attributes in access specifiers.
...
Change-Id: Ie85b8264c9579e8c8312e30018280fb11f95edda
Reviewed-on: http://codereview.qt-project.org/6328
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com >
Reviewed-by: Erik Verbruggen <erik.verbruggen@nokia.com >
Sanity-Review: Erik Verbruggen <erik.verbruggen@nokia.com >
2011-10-11 12:45:04 +02:00
Christian Kamm
71b2cbef9a
CDB breakpoints: Fix line adjustment in case statements.
...
Task-number: QTCREATORBUG-6207
Change-Id: I4df50a412dd960a0d53a824a6c4a93712bd743e8
Reviewed-on: http://codereview.qt-project.org/5964
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com >
2011-10-04 09:35:45 +02:00
Christian Kamm
151475a0fe
C++: Fix function return type printing.
...
We used to print T * foo(), but our style suggests T *foo().
Change-Id: Ie3b0ce6b620785ec98aeb394f7955ce959440619
Reviewed-on: http://codereview.qt-project.org/4634
Reviewed-by: Leandro T. C. Melo <leandro.melo@nokia.com >
2011-09-12 11:16:39 +02:00
Christian Kamm
930e7b711d
C++ insert def: Insert next to surrounding definitions.
...
Change-Id: I1bef659084727d7fe69670c991ee5efe2be66497
Reviewed-on: http://codereview.qt.nokia.com/3713
Reviewed-by: Leandro T. C. Melo <leandro.melo@nokia.com >
2011-08-30 09:03:08 +02:00
Christian Kamm
1f9be179f0
C++ indenter: Make continuations after ( consistent.
...
Change-Id: Iae780127065e3fce274db10e173f5c0bde15bd92
Reviewed-on: http://codereview.qt.nokia.com/1229
Reviewed-by: Leandro T. C. Melo <leandro.melo@nokia.com >
2011-07-06 13:06:42 +02:00
hjk
a322bd606f
Replace qt-info@nokia.com with info@qt.nokia.com
...
Change-Id: I61e7cf189a1c4ea04e2a88a80a4f15e43cd3c018
Reviewed-on: http://codereview.qt.nokia.com/1187
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com >
Reviewed-by: Eike Ziller <eike.ziller@nokia.com >
2011-07-06 11:14:01 +02:00
Christian Kamm
e2cdaf7888
C++ indenter: Fix function declaration continuation indent.
...
Change-Id: I0ebe1f0f531cb4830f80b80c6bb52caeaee01353
Reviewed-on: http://codereview.qt.nokia.com/1167
Reviewed-by: Leandro T. C. Melo <leandro.melo@nokia.com >
2011-07-06 10:00:05 +02:00
Christian Kamm
794f296701
C++ indenter: Fix multiple initializers.
...
Task-number: QTCREATORBUG-4993
Change-Id: I0f7d541eb7b26c37b8167e30e2949b6b939fe4b8
Reviewed-on: http://codereview.qt.nokia.com/297
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com >
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com >
2011-06-01 11:14:50 +02:00
Christian Kamm
f762d93702
C++ indenter: Fix indent in body of function with default argument.
...
Change-Id: I9d4f5b3ae7b8a59f8350cf756979a3a430398112
Reviewed-on: http://codereview.qt.nokia.com/206
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com >
2011-05-30 12:02:04 +02:00
Christian Kamm
779fafcbfe
Make C++ code style configurable.
...
Change-Id: Iaf08edb2361146e6b5e1cbafdb716a23c938875b
Done-with: Jarek Kobus
Task-number: QTCREATORBUG-2670
Task-number: QTCREATORBUG-4310
Task-number: QTCREATORBUG-2763
Task-number: QTCREATORBUG-3623
Task-number: QTCREATORBUG-567
Reviewed-on: http://codereview.qt.nokia.com/74
Reviewed-by: Leandro T. C. Melo <leandro.melo@nokia.com >
Reviewed-by: Jarek Kobus <jaroslaw.kobus@nokia.com >
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com >
2011-05-24 12:45:07 +02:00
Christian Kamm
c5ce20c5f7
C++ indenter: Treat extern "C" like namespace.
...
Change-Id: Ib0553d35fbd83aada2b8809aa008b1f75ca77c32
Done-with: Erik Verbruggen
Reviewed-on: http://codereview.qt.nokia.com/14
Reviewed-by: Erik Verbruggen <erik.verbruggen@nokia.com >
2011-05-19 13:23:50 +02:00
Christian Kamm
86d5df063c
C++ indenter: Fix extra specifier in return type of func decl.
...
Like
struct Foo bar() { }
Change-Id: I946937c23d1660909757952a5a3bd400c4781826
Reviewed-on: http://codereview.qt.nokia.com/13
Reviewed-by: Erik Verbruggen <erik.verbruggen@nokia.com >
2011-05-19 13:14:07 +02:00
Oswald Buddenhagen
67704b8b41
move src/shared/cplusplus/ -> src/libs/3rdparty/cplusplus/
...
Approved-by: legal
2011-05-16 11:05:30 +02:00
Friedemann Kleint
56fea4ad3a
Fix test compile.
2011-05-09 15:08:21 +02:00
Erik Verbruggen
49814d9ea5
Class to find breakpoint positions for CDB.
...
Reviewed-by: Friedemann Kleint
2011-05-09 13:43:19 +02:00