Anders Carlsson
5de832ecfa
ActOnReturnStmt should also take a FullExprArg.
...
llvm-svn: 72641
2009-05-30 21:42:34 +00:00
Anders Carlsson
5e9444f541
AddInitializerToDecl needs to take a full expression.
...
llvm-svn: 72640
2009-05-30 21:37:25 +00:00
Anders Carlsson
f8e916de85
Update Xcode project
...
llvm-svn: 72639
2009-05-30 21:32:24 +00:00
Anders Carlsson
c78576e250
Add the newly created temporary to the ExprTemporaries stack.
...
llvm-svn: 72638
2009-05-30 21:21:49 +00:00
Anders Carlsson
4f44fd5c6f
Get rid of CXXTempVarDecl.
...
llvm-svn: 72637
2009-05-30 21:10:34 +00:00
Eli Friedman
f7f9f68722
Some small fixes for fields of reference type.
...
llvm-svn: 72636
2009-05-30 21:09:44 +00:00
Bruno Cardoso Lopes
9499ab3287
Add AMD64 elf machine type
...
llvm-svn: 72635
2009-05-30 21:05:47 +00:00
Anders Carlsson
a29ded9ba8
Stop using CXXTempVarDecl and use CXXTemporary instead.
...
llvm-svn: 72634
2009-05-30 21:05:25 +00:00
Anders Carlsson
4b2434da54
Remove VarDecl from CXXConstructExpr.
...
llvm-svn: 72633
2009-05-30 20:56:46 +00:00
Anders Carlsson
b228818554
Bind temporaries correctly when instantiating expressions.
...
llvm-svn: 72632
2009-05-30 20:52:37 +00:00
Bruno Cardoso Lopes
a194c3a69e
First patch in the direction of splitting MachineCodeEmitter in two subclasses:
...
JITCodeEmitter and ObjectCodeEmitter. No functional changes yet. Patch by Aaron Gray
llvm-svn: 72631
2009-05-30 20:51:52 +00:00
Anders Carlsson
28486d420b
Remove VarDecl from CheckInitializerTypes now that CXXConstructExpr doesn't need to take a VarDecl anymore. (It still does, but it won't for long)
...
llvm-svn: 72630
2009-05-30 20:41:30 +00:00
Anders Carlsson
2d4cada7f7
Add Sema::MaybeBindToTemporary which takes an expression and (if needed) wraps it in a CXXBindTemporaryExpr. Use this when creating CXXTemporaryObjectExprs.
...
llvm-svn: 72629
2009-05-30 20:36:53 +00:00
Anders Carlsson
ffda606612
Small fixes to CXXTemporary and CXXBindTemporaryExpr.
...
llvm-svn: 72628
2009-05-30 20:34:37 +00:00
Anders Carlsson
993a4b3080
Add a CXXBindTemporaryExpr.
...
llvm-svn: 72627
2009-05-30 20:03:25 +00:00
Anders Carlsson
f337d8c515
Add a CXXTemporary class. Not used yet.
...
llvm-svn: 72626
2009-05-30 19:54:15 +00:00
Chris Lattner
221895303c
fix PR4284, a bug in simplifylibcalls handling memcmp. Patch by
...
Benjamin Kramer!
llvm-svn: 72625
2009-05-30 18:43:04 +00:00
Anders Carlsson
36b75a4619
Replace a cast with a dyn_cast as suggested by Doug.
...
llvm-svn: 72624
2009-05-30 17:26:39 +00:00
Nick Lewycky
8e2c4f4716
Metadata uses metadata type not empty struct.
...
llvm-svn: 72623
2009-05-30 16:08:30 +00:00
Mike Stump
5b6bb31eae
Add some documentation.
...
llvm-svn: 72622
2009-05-30 15:19:29 +00:00
Mike Stump
b807c9c622
Cleqnup ideas from Chris, thanks.
...
llvm-svn: 72621
2009-05-30 14:43:18 +00:00
Duncan Sands
24ad1feb77
Adjust these tests now that "extern inline"
...
functions are being output with bodies and
available_externally linkage.
llvm-svn: 72620
2009-05-30 13:57:05 +00:00
Evan Cheng
7142ad75a1
(i64 (zext (srl GR32 8))) -> movzbl AH is not safe since srl 8 only clear the top 8 bits.
...
llvm-svn: 72618
2009-05-30 08:43:27 +00:00
Douglas Gregor
5f478b78c0
AST printing for C++ base classes
...
llvm-svn: 72617
2009-05-30 06:58:37 +00:00
Douglas Gregor
182319375a
Pretty printing and improved representation for namespace alias declarations
...
llvm-svn: 72616
2009-05-30 06:48:27 +00:00
Eli Friedman
1730424516
Add a hack to prevent us from printing out the __builtin_va_list
...
declaration in -ast-print mode.
llvm-svn: 72615
2009-05-30 06:35:22 +00:00
Douglas Gregor
3bc6e4c72a
Printing for using directives, e.g.,
...
using namespace std::debug;
Extended UsingDirectiveDecl to store the nested-name-specifier that
precedes the nominated namespace.
llvm-svn: 72614
2009-05-30 06:31:56 +00:00
Douglas Gregor
2d042f1cf4
Never suppress specifiers when printing the parameters of a function
...
declaration.
llvm-svn: 72613
2009-05-30 05:39:39 +00:00
Eli Friedman
c4fc839c57
Pass an ASTContext into Stmt::printPretty.
...
llvm-svn: 72612
2009-05-30 05:32:46 +00:00
Eli Friedman
0905f14e62
Pass an ASTContext into Stmt::printPretty.
...
llvm-svn: 72611
2009-05-30 05:19:26 +00:00
Nick Lewycky
adbc284666
Give embedded metadata its own type instead of relying on EmptyStructTy.
...
llvm-svn: 72610
2009-05-30 05:06:04 +00:00
Eli Friedman
ef334fdfa2
Add a Stmt::printPretty overload which takes an ASTContext; start
...
transitioning callers over to pass one in.
llvm-svn: 72609
2009-05-30 05:03:24 +00:00
Eli Friedman
796358498f
Expose an API to print a group of decls (like "int a,b;").
...
Make StmtPrinter use DeclPrinter to print all declarations. Merge
declarations in the limited case of an unnamed TagDecl followed by one
or more declarations using that TagDecl directly. Change
SuppressTypeSpecifiers to the more general SuppressSpecifiers, and
use it to suppress stuff like "typedef" and "extern". Replace
OwnedTag with SuppressTag, since it's more convenient to print
declarations from DeclPrinter at the moment.
improvements to declaration printing. Fix pretty-printing for K&R
function definitions and __builtin_va_arg.
We're now to the point where the pretty-printing output for non-trivial
programs can actually be piped back into clang.
llvm-svn: 72608
2009-05-30 04:20:30 +00:00
Mike Stump
2346cd2a10
Improve __builtin_nanf support; we now can deal with them as constants.
...
llvm-svn: 72607
2009-05-30 03:56:50 +00:00
Mike Stump
799bf5855e
Add support for letting the client choose different flavors of NaNs. Testcase to be
...
added in clang.
llvm-svn: 72606
2009-05-30 03:49:43 +00:00
Eli Friedman
258ffef5b5
Fix some test failures involving -ast-print.
...
llvm-svn: 72605
2009-05-30 01:45:29 +00:00
Bill Wendling
09f17a8479
Untabification.
...
llvm-svn: 72604
2009-05-30 01:09:53 +00:00
Bill Wendling
c1b9bff66d
Untabify.
...
llvm-svn: 72603
2009-05-30 00:58:37 +00:00
Douglas Gregor
36098ff480
Clean up printing for Objective-C, designated initializers.
...
llvm-svn: 72602
2009-05-30 00:56:08 +00:00
Anders Carlsson
65d5820892
Add a member lookup criteria constructor for searching for overridden virtual member functions. Use this instead of regular name lookup when checking for overriding functions so we will see declarations that would otherwise be hidden. Fixes 6902298.
...
llvm-svn: 72601
2009-05-30 00:52:53 +00:00
Evan Cheng
9a75111bc6
Untabify.
...
llvm-svn: 72600
2009-05-30 00:48:34 +00:00
Eli Friedman
15ea880358
Some enhancements to DeclStmt printing. Some of this should
...
move to DeclPrinter.cpp, but I haven't quite worked out how best to do
that.
llvm-svn: 72599
2009-05-30 00:19:54 +00:00
Eli Friedman
d5ef49ff54
Add support for PrintingPolicy::SuppressTypeSpecifiers to type printing.
...
(I have a work-in-progress patch which uses this.)
llvm-svn: 72598
2009-05-30 00:10:16 +00:00
Douglas Gregor
278f52ec29
Refactor and clean up the AST printer, so that it uses a DeclVisitor,
...
walks through DeclContexts properly, and prints more of the
information available in the AST. The functionality is still available
via -ast-print, -ast-dump, etc., and also via the new member functions
Decl::dump() and Decl::print().
llvm-svn: 72597
2009-05-30 00:08:05 +00:00
Anders Carlsson
01bcef4a17
Make the LookupBase boolean an enum instead.
...
llvm-svn: 72594
2009-05-29 23:42:05 +00:00
Anton Korobeynikov
b6f4538683
Add placeholder for thumb2 stuff
...
llvm-svn: 72593
2009-05-29 23:41:08 +00:00
Anders Carlsson
0a63741a3f
Add code for emitting C++ destructors. Not used yet.
...
llvm-svn: 72591
2009-05-29 21:03:38 +00:00
Douglas Gregor
7de5966d76
Create a new PrintingPolicy class, which we pass down through the AST
...
printing logic to help customize the output. For now, we use this
rather than a special flag to suppress the "struct" when printing
"struct X" and to print the Boolean type as "bool" in C++ but "_Bool"
in C.
llvm-svn: 72590
2009-05-29 20:38:28 +00:00
Bill Wendling
006459ecd4
Enable GVN Load PRE.
...
llvm-svn: 72589
2009-05-29 20:38:16 +00:00
Eli Friedman
bd32745978
Make sure we don't give the wrong warning, and make sure not to set
...
hadError (suppressing future diagnostics) if we didn't print an
error.
llvm-svn: 72588
2009-05-29 20:20:05 +00:00