- Jul 15, 2009
-
-
Steve Naroff authored
Implement the ObjC pseudo built-in types as clang "BuiltinType's". I say pseudo built-in types, since Sema still injects a typedef for recognition (i.e. they aren't truly built-ins from a parser perspective). This removes the static data/methods on ObjCObjectPointerType while preserving the nice API (no need to fiddle with ASTContext:-). This patch also adds Type::isObjCBuiltinType(). This should be the last fairly large patch related to recrafting the ObjC type system. The follow-on patches should be fairly small. llvm-svn: 75808
-
- Jul 14, 2009
-
-
Steve Naroff authored
I don't love the name, however it simplifies the code and is a worthwhile change. If/when we come up with a better name, we can do a search/replace. llvm-svn: 75650
-
Fariborz Jahanian authored
semantics of order of construction [class.init]. llvm-svn: 75649
-
Steve Naroff authored
Note: One day, it might be useful to consider adding this info to DeclGroup (as the comments in FunctionDecl/VarDecl suggest). For now, I think this works fine. I considered moving this to ValueDecl (a common ancestor of FunctionDecl/VarDecl/FieldDecl), however this would add overhead to EnumConstantDecl (which would burn memory and isn't necessary). llvm-svn: 75635
-
Alisdair Meredith authored
llvm-svn: 75622
-
Argyrios Kyrtzidis authored
For C++ overloaded operator calls, set the source location of the DeclRefExpr to the location of the operator. llvm-svn: 75600
-
Argyrios Kyrtzidis authored
- Declaration context of ParmVarDecls (that we got from the Declarator) was not their containing function. - C++ out-of-line method definitions didn't get an access specifier. Both were exposed by a crash when emitting a C++ method to a PCH file (assert at Decl::CheckAccessDeclContext()). llvm-svn: 75597
-
Argyrios Kyrtzidis authored
llvm-svn: 75591
-
- Jul 13, 2009
-
-
Steve Naroff authored
llvm-svn: 75509
-
Steve Naroff authored
llvm-svn: 75505
-
Steve Naroff authored
- Improve comment for Type::getPointeeType(). - Remove a couple redundant casts/returns. - Fix 80 column violations for all getAsStringInternal() methods. llvm-svn: 75485
-
http://llvm.org/viewvc/llvm-project?view=rev&revision=75314Steve Naroff authored
Still more to come...just wanted to get the no-brainers out of the way. llvm-svn: 75477
-
- Jul 11, 2009
-
-
Anders Carlsson authored
Implement more of C++0x 'auto'. A variable with an auto type specifier must have an initializer. Also, move some tests around to match the C++0x draft better. llvm-svn: 75322
-
Ted Kremenek authored
warning: ‘OPT’ may be used uninitialized in this function Now OPT is initialized to NULL. I'm not certain if this is the correct fix; others please review. llvm-svn: 75321
-
Anders Carlsson authored
llvm-svn: 75315
-
Steve Naroff authored
The idea is to segregate Objective-C "object" pointers from general C pointers (utilizing the recently added ObjCObjectPointerType). The fun starts in Sema::GetTypeForDeclarator(), where "SomeInterface *" is now represented by a single AST node (rather than a PointerType whose Pointee is an ObjCInterfaceType). Since a significant amount of code assumed ObjC object pointers where based on C pointers/structs, this patch is very tedious. It should also explain why it is hard to accomplish this in smaller, self-contained patches. This patch does most of the "heavy lifting" related to moving from PointerType->ObjCObjectPointerType. It doesn't include all potential "cleanups". The good news is additional cleanups can be done later (some are noted in the code). This patch is so large that I didn't want to include any changes that are purely aesthetic. By making the ObjC types truly built-in, they are much easier to work with (and require fewer "hacks"). For example, there is no need for ASTContext::isObjCIdStructType() or ASTContext::isObjCClassStructType()! We believe this change (and the follow-up cleanups) will pay dividends over time. Given the amount of code change, I do expect some fallout from this change (though it does pass all of the clang tests). If you notice any problems, please let us know asap! Thanks. llvm-svn: 75314
-
- Jul 10, 2009
-
-
Fariborz Jahanian authored
in their order of construction for each class and use it to to check on propery order of base class construction under -Wreorder option. llvm-svn: 75270
-
Fariborz Jahanian authored
llvm-svn: 75178
-
- Jul 09, 2009
-
-
Fariborz Jahanian authored
class object's base and members under -Wreorder flag. llvm-svn: 75168
-
Anders Carlsson authored
llvm-svn: 75152
-
Anders Carlsson authored
llvm-svn: 75150
-
Douglas Gregor authored
Add test for C++ [over.over.]p1, the contexts in which one can take the address of an overloaded function. llvm-svn: 75146
-
Anders Carlsson authored
Store the isAddressOfOperand in the UnresolvedDeclRefExpr, so that we can pass it when instantiating the expr. Fixes another member pointer bug. llvm-svn: 75075
-
Douglas Gregor authored
address of an overloaded function (which may involve both functions and function templates). llvm-svn: 75069
-
- Jul 08, 2009
-
-
Anders Carlsson authored
It's not allowed to form member pointers to members that have reference type. Add a test for this and the rest of [dcl.mptr]p3. llvm-svn: 75054
-
Douglas Gregor authored
function template. Most of the change here is in factoring out the common bits used for template argument deduction from a function call and when taking the address of a function template. llvm-svn: 75044
-
Douglas Gregor authored
llvm-svn: 74999
-
Douglas Gregor authored
namespaces based on the template arguments of a class template specialization type. llvm-svn: 74993
-
Fariborz Jahanian authored
when struct variables with GC'able members are copied into. Will provide a test case later. llvm-svn: 74984
-
Chris Lattner authored
Also, enable them in sema so that they are tested, and now that the x86 backend has stablized. llvm-svn: 74983
-
Douglas Gregor authored
llvm-svn: 74971
-
Douglas Gregor authored
llvm-svn: 74966
-
Douglas Gregor authored
implement C++ [temp.deduct.call]p3b3, which allows a template-id parameter to match a derived class of the argument, while deducing template arguments. llvm-svn: 74965
-
- Jul 07, 2009
-
-
Nate Begeman authored
llvm-svn: 74951
-
Sebastian Redl authored
llvm-svn: 74943
-
Anders Carlsson authored
llvm-svn: 74937
-
Fariborz Jahanian authored
llvm-svn: 74935
-
Douglas Gregor authored
declaration for a builtin. llvm-svn: 74917
-
Douglas Gregor authored
FILE type, rather than using name lookup to find FILE within the translation unit. Within precompiled headers, FILE is treated as yet another "special type" (like __builtin_va_list). This change should provide a performance improvement (not verified), since the lookup into the translation unit declaration forces the (otherwise unneeded) construction of a large hash table. More importantly, with precompiled headers, the construction of that table requires deserializing most of the top-level declarations from the precompiled header, which are then unused. Fixes PR 4509. llvm-svn: 74911
-
- Jul 06, 2009
-
-
Douglas Gregor authored
Fix a problem with false diagnostics when comparing distinct NULL pointer types, from David Majnemer llvm-svn: 74850
-