summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaCXX/expressions.cpp
Commit message (Collapse)AuthorAgeFilesLines
* [Lit Test] Updated 34 Lit tests to be C++11 compatible.Charles Li2015-11-171-0/+5
| | | | | | | Added expected diagnostics new to C++11. Expanded RUN line to: default, C++98/03 and C++11. llvm-svn: 253371
* [SemaCXX] Silence -Wconstant-logical-operand if the operand is a 0/1 from a ↵Argyrios Kyrtzidis2014-04-281-0/+10
| | | | | | | | | | | macro. Libraries specify enabled/disabled features using macro defs of 0/1, in such cases the -Wconstant-logical-operand is noise. rdar://15410291 llvm-svn: 207386
* Fixed error recovery if sizeof is used without parenthesisSerge Pavlov2014-01-151-0/+7
| | | | | | | | | | | Changes made in r192200 fixed PR16992, which requested fixit suggesting parenthesis if sizeof is followed by type-id. However expression in form T() followed by ')' was incorrectly considered as a type-id if 'T' is typedef name. This change fixes this case. Differential Revision: http://llvm-reviews.chandlerc.com/D2440 llvm-svn: 199284
* Improve some of the conversion warnings to fire on conversion to bool.David Blaikie2012-05-151-1/+1
| | | | | | | | | | | Moves the bool bail-out down a little in SemaChecking - so now -Wnull-conversion and -Wliteral-conversion can fire when the target type is bool. Also improve the wording/details in the -Wliteral-conversion warning to match the -Wconstant-conversion. llvm-svn: 156826
* Add fixit notes for -Wconstant-logical-operand.Matt Beaumont-Gay2011-08-151-21/+54
| | | | llvm-svn: 137620
* Remove warnings of constant operands of logical operators from template ↵Richard Trieu2011-07-151-0/+22
| | | | | | | | | | | | | | instantiations. Upon instantiation of template, value-dependent parameters are replaced by equivalent literals, so code like: template<unsigned int A, unsigned int B> struct S { int foo() { int x = A && B; } } will not warn on A && B on every instantiation. This will still warn on other cases inside templates, which will be caught on checking the template definition. llvm-svn: 135222
* Expand the coverage of the warning for constants on the RHS of logical operands:Chandler Carruth2011-05-311-0/+31
| | | | | | | | | | | | return f() || -1; where the user meant to write '|'. This bootstraps without any additional warnings. Patch by Richard Trieu. llvm-svn: 132327
* Flesh out test.John McCall2010-10-121-5/+16
| | | | llvm-svn: 116292
* I just do what the comments tell me to do.John McCall2010-10-121-0/+7
| | | | llvm-svn: 116289
* Move the test for radar 8018252 toFariborz Jahanian2010-08-241-0/+7
| | | | | | SemaCXX/expressions.cpp. llvm-svn: 111988
* Update tests to use %clang_cc1 instead of 'clang-cc' or 'clang -cc1'.Daniel Dunbar2009-12-151-1/+1
| | | | | | | | | - 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
* Rename clang to clang-cc.Daniel Dunbar2009-03-241-1/+1
| | | | | | Tests and drivers updated, still need to shuffle dirs. llvm-svn: 67602
* Add missing test case for operator ! result type.Sebastian Redl2009-01-191-0/+9
llvm-svn: 62532
OpenPOWER on IntegriCloud