diff options
author | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2009-05-22 21:09:47 +0000 |
---|---|---|
committer | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2009-05-22 21:09:47 +0000 |
commit | f73f2d28a279b6f7e38830549ea6ae4c0640176c (patch) | |
tree | ae2b179b8f6d41cfe675d91d67c75c51145e7892 /clang/lib/AST/ExprCXX.cpp | |
parent | 48ce3b553b094a4209439ec7b322b730f47988e2 (diff) | |
download | bcm5719-llvm-f73f2d28a279b6f7e38830549ea6ae4c0640176c.tar.gz bcm5719-llvm-f73f2d28a279b6f7e38830549ea6ae4c0640176c.zip |
The disambiguation process for ambiguous paren expressions is not "side effects free", e.g:
(T(*)(int[x+y]));
is an (invalid) paren expression, but "x+y" will be parsed as part of the (rejected) type-id,
so unnecessary Action calls are made for an unused (and possibly leaked) "x+y".
Use a different scheme, similar to parsing inline methods. The parenthesized tokens are cached,
the context that follows is determined (possibly by parsing a cast-expression),
and then we re-introduce the cached tokens into the token stream and parse them appropriately.
llvm-svn: 72279
Diffstat (limited to 'clang/lib/AST/ExprCXX.cpp')
0 files changed, 0 insertions, 0 deletions