Commit Graph

16 Commits

Author SHA1 Message Date
Christian Kamm
a81389356e C++11: Fix and add test for simple decltype uses.
Change-Id: I7f843fa96e33671ecb135b9db6f68d9f2cbf2fac
Reviewed-by: hjk <qthjk@ovi.com>
2012-09-24 12:08:25 +02:00
Christian Kamm
83da5f68be C++11: Allow for typename Foo<T>{}, Foo{} and int{}.
As a postfix expression.

Change-Id: I65cae0571080a9fb699af61c661328ef06f97890
Reviewed-by: hjk <qthjk@ovi.com>
2012-09-19 12:21:31 +02:00
Christian Kamm
2aa27e6d22 C++11: Make expression-list expand to initializer-list.
This will fix a couple more places where brace-init-lists and
pack expansions are allowed but are not currently accepted by
the parser. For example:

foo(abc...);

now parses correctly.

Change-Id: I93710cef35154fea8437329f3174e4a2d56637b8
Reviewed-by: hjk <qthjk@ovi.com>
2012-09-19 12:20:58 +02:00
Christian Kamm
392c80c6e4 C++11: Fix use of >> in template arguments.
Change-Id: Ic99ca897e7a3b9c82cf8c5093a90bf9c88dbb0ed
Reviewed-by: hjk <qthjk@ovi.com>
2012-09-19 11:58:34 +02:00
Christian Kamm
44c9cef30a C++11: Make 'enum struct', enum-base and opaque enum decls work.
For declarations like:
enum struct Foo : long int;

Change-Id: Id813efdbc31c8d70a4b40bb0101dc33a8dd2556a
Reviewed-by: hjk <qthjk@ovi.com>
2012-09-19 11:57:23 +02:00
Christian Kamm
8711121197 C++11: Parse alias declarations.
The parser no longer fails declarations like:
using Foo = std::vector<int>::iterator;

Change-Id: Ib3a552ebbe0147fa138db6448a52cdba8f9b9207
Reviewed-by: hjk <qthjk@ovi.com>
2012-09-19 11:56:33 +02:00
Christian Kamm
9bd86e7d68 C++11: Allow brace-init-list in range-for statement.
Also drop the unused 'initializer' member from
RangeBasedForStatementAST.

Change-Id: I078ebbc85cafa643af4bfe62d698bf7de71360e4
Reviewed-by: hjk <qthjk@ovi.com>
2012-09-19 11:54:50 +02:00
Christian Kamm
ecd54059d3 C++11: Add alignof() expression.
Change-Id: Id3fb30b9a16ea724bab0d5b05e8cbddb0064e6eb
Reviewed-by: hjk <qthjk@ovi.com>
2012-09-19 11:53:46 +02:00
Christian Kamm
8c1a45565c C++11: Accept ref-qualifiers in function declarators.
Means
void foo() const &; void bar() &&;
and the corresponding pointer-to-member declarators
now parse.

Change-Id: Idbf295bd4f51cd5d9e38efcac1940b8cc2e32fce
Reviewed-by: hjk <qthjk@ovi.com>
2012-09-19 11:51:48 +02:00
Christian Kamm
b9f6f1bcf7 C++11: Allow uniform initialization in ctor init lists.
So
class C { C() : _x{12}, _y({12}) {} };
now parses correctly.

Change-Id: I4281dcb0541a86b550e74630cad6ae0a59fef1b4
Reviewed-by: hjk <qthjk@ovi.com>
2012-09-19 11:47:49 +02:00
Christian Kamm
903ba378c2 C++11: Don't fail on = default and = delete initializers.
These are converted to IdExpr(SimpleName(token)) initializers.

Change-Id: I1e85c4b261ca028dc75ffe6c00e1090630c2957c
Reviewed-by: hjk <qthjk@ovi.com>
2012-09-19 11:46:51 +02:00
Christian Kamm
813846232b C++11: Allow for brace initializers like T v{1, 2}.
And add a basic test.

Change-Id: I3b8b87d51a9da154758d17380bba5922795f675c
Reviewed-by: hjk <qthjk@ovi.com>
2012-09-17 14:47:14 +02:00
Eike Ziller
e0e8cf3ada Contact -> qt-project.org
Change-Id: I7134d7de30bcf9f9dcfad42520dd45ee083a852d
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-07-19 13:23:21 +02: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