Kaelyn Takata
22101f9689
Continue parsing an expression list even after an error is encountered.
...
Otherwise, multiple errors such as having unknown identifiers for two
arguments won't be diagnosed properly (e.g. only the first one would
have a diagnostic message if typo correction fails even though both
would be diagnosed if typo correction suggests a replacement).
llvm-svn: 213003
2014-07-14 22:48:10 +00:00
David Majnemer
767c1f8428
Make wording for certain invalid unary expressions more consistent.
...
An invalid decltype expression like 'decltype int' gives:
error: expected '(' after 'decltype'
This makes it so 'sizeof int' gives a similar one:
error: expected parentheses around type name in sizeof expression
llvm-svn: 192258
2013-10-09 00:22:23 +00:00
Serge Pavlov
5815940edc
Fixed messages in tests.
...
llvm-svn: 192208
2013-10-08 17:38:38 +00:00
Serge Pavlov
aa57a64ef6
Add fixits suggesting parenthesis around type name in expressions like sizeof.
...
This fixes PR16992 - Fixit missing when "sizeof type" found.
llvm-svn: 192200
2013-10-08 16:56:30 +00:00
John McCall
c5e6b97523
Diagnose a missing ')' on what looks like a statement expression.
...
A situation where we can get an invalid ExprResult without an error.
Fixes PR8394. Patch by Justin Bogner!
llvm-svn: 128979
2011-04-06 02:35:25 +00:00
Abramo Bagnara
932e393fda
Treat __extension__ like ParenExpr.
...
llvm-svn: 116569
2010-10-15 07:51:18 +00:00
Douglas Gregor
67ca40c419
Eliminate the "minimal" and printing parser actions, which only ever
...
worked for C anyway. Also kills the -cc1 options -parse-noop and
-parse-print-callbacks.
llvm-svn: 109392
2010-07-26 04:08:02 +00:00
Daniel Dunbar
8fbe78f6fc
Update tests to use %clang_cc1 instead of 'clang-cc' or 'clang -cc1'.
...
- This is designed to make it obvious that %clang_cc1 is a "test variable"
which is substituted. It is '%clang_cc1' instead of '%clang -cc1' because it
can be useful to redefine what gets run as 'clang -cc1' (for example, to set
a default target).
llvm-svn: 91446
2009-12-15 20:14:24 +00:00
Chris Lattner
0d6c061401
Improve error recovery for calls, fixing:
...
PR3972: Poor diagnostic with missing ')'
llvm-svn: 68932
2009-04-13 00:10:38 +00:00
Daniel Dunbar
a45cf5b6b0
Rename clang to clang-cc.
...
Tests and drivers updated, still need to shuffle dirs.
llvm-svn: 67602
2009-03-24 02:24:46 +00:00
Eli Friedman
eb3a9b03ab
Fix for PR3418: make sure to handle the RHS of expressions starting with
...
__extension__. This sort of construct shows up in the gcc source code.
llvm-svn: 63100
2009-01-27 08:43:38 +00:00
Chris Lattner
47791a4051
Parse "sizeof(arr)[0]" as a sizeof of an expr if arr
...
is an expression.
llvm-svn: 44065
2007-11-13 20:50:37 +00:00
Chris Lattner
6d5922fd66
reenable this.
...
llvm-svn: 41397
2007-08-25 05:31:19 +00:00
Chris Lattner
a206358bb6
test the parser only, not sema.
...
llvm-svn: 41395
2007-08-25 05:26:51 +00:00
Chris Lattner
cf9be2d315
update tests
...
llvm-svn: 39786
2007-07-12 16:52:08 +00:00
Chris Lattner
5b6032ab3c
new offsetof testcase
...
llvm-svn: 38892
2006-08-12 19:15:40 +00:00
Chris Lattner
2c5c421203
add test4
...
llvm-svn: 38886
2006-08-12 18:11:24 +00:00
Chris Lattner
e66218bf49
Split the expression tests out of statements.c into expressions.c
...
llvm-svn: 38882
2006-08-12 17:19:28 +00:00