Commit Graph

6 Commits

Author SHA1 Message Date
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 3eb172a02b Teach sema and codegen about the difference between address of labels,
which is a common idiom to improve PIC'ness of code using the addr of
label extension.  This implementation is a gross hack, but the only other
alternative would be to teach evalutate about this horrid combination.
While GCC allows things like "&&foo - &&bar + 1", people don't use this
in practice.  This implements PR5131.

llvm-svn: 83957
2009-10-13 07:14:16 +00:00
Chris Lattner 9842a4dcb1 merge an indirect goto test into statements, add another
hairier (but nonsensical) example.

llvm-svn: 83951
2009-10-13 06:52:43 +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
Chris Lattner 871e0ceffb explicitly document that return statement argument does not necessarily follow the result type of the function. Add testcase.
llvm-svn: 46823
2008-02-06 21:20:34 +00:00
Chris Lattner a65e1f3b31 Move promoteExprToType from being a static method in SemaExpr.cpp to being
a method named ImpCastExprToType in Sema.

Use this method to insert implicit casts for case statements from their 
operand type to the condition type of the switch.  This fixes a crash on
test/CodeGen/statements.c, reported by Eli Friedman.

llvm-svn: 46083
2008-01-16 19:17:22 +00:00