]>
granicus.if.org Git - clang/log
Mike Stump [Mon, 5 Oct 2009 21:58:44 +0000 (21:58 +0000)]
Respect alignments better.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83328
91177308 -0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Mon, 5 Oct 2009 21:33:42 +0000 (21:33 +0000)]
Fix C90 compile warning about mixed declarations and code.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83327
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Mon, 5 Oct 2009 21:32:49 +0000 (21:32 +0000)]
tweaked my last patch to 1) preserve the protocol in
extension class's protocol list so its AST is complete.
2) Because of this no need to issue warning on unimplemeted
methods coming from the extended class protocols
because warning is issued when class definition is seen.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83326
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 5 Oct 2009 21:16:22 +0000 (21:16 +0000)]
remove this test, grepping for define isn't really testing anything.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83325
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Mon, 5 Oct 2009 21:07:28 +0000 (21:07 +0000)]
Encode the Clang branch and Subversion revision into a PCH file, and
assume that PCH files from different Clang revisions are not
compatible. Addresses <rdar://problem/
7266572 >.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83323
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Mon, 5 Oct 2009 20:41:32 +0000 (20:41 +0000)]
Patch to implement Protocols on class extensions.
<rdar://problem/
7269631 > Protocols on class extensions don't work
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83322
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Mon, 5 Oct 2009 20:33:49 +0000 (20:33 +0000)]
Provide a common set of routines in Version.h that return Subversion
branch/revision information. Use that information in the driver,
rather than one-off branch/revision computation.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83321
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Mon, 5 Oct 2009 18:52:24 +0000 (18:52 +0000)]
Pre-commit commit to get URL keyword expansion for Clang version information
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83319
91177308 -0d34-0410-b5e6-
96231b3b80d8
Steve Naroff [Mon, 5 Oct 2009 17:58:19 +0000 (17:58 +0000)]
- Fix assert in clang_getCursorDecl (having to do with recently added ObjC_ProtocolRef).
- Make sure CHECK: lines in test case match the expected output.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83316
91177308 -0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Mon, 5 Oct 2009 13:47:21 +0000 (13:47 +0000)]
Use new predicates for some type equality tests.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83303
91177308 -0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Mon, 5 Oct 2009 13:12:17 +0000 (13:12 +0000)]
Add a -nostdclanginc flag to clang-cc that prevents it from searching
its own binary-relative headers. Useful when using clang's preprocessor
with gcc.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83302
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Sat, 3 Oct 2009 19:56:56 +0000 (19:56 +0000)]
Pass the canonical method decl to GetVtableIndex. Fixes PR5120.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83272
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Sat, 3 Oct 2009 19:43:08 +0000 (19:43 +0000)]
Implement code generation of member function pointer calls. Fixes PR5121.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83271
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Sat, 3 Oct 2009 17:40:22 +0000 (17:40 +0000)]
Create CXXMemberCallExpr for pointer-to-member calls.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83268
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Sat, 3 Oct 2009 16:30:22 +0000 (16:30 +0000)]
Ignore No-op casts when evaluating lvalue expressions. Fixes PR5122.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83267
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Sat, 3 Oct 2009 15:43:24 +0000 (15:43 +0000)]
Teach AggExprEmitter about pointers to member functions.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83266
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Sat, 3 Oct 2009 15:13:22 +0000 (15:13 +0000)]
Handle base-to-derived casts of member function pointers in CGExprConstant.cpp
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83265
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Sat, 3 Oct 2009 15:02:02 +0000 (15:02 +0000)]
Handle members to function pointers in CGExprConstant.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83264
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Sat, 3 Oct 2009 14:56:57 +0000 (14:56 +0000)]
Move some functions from CodeGenFunctions to CodeGenModule so they can be used by CGExprConstant.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83263
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Sat, 3 Oct 2009 14:39:13 +0000 (14:39 +0000)]
Rewrite member function pointer test not to rely on -O2.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83262
91177308 -0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Fri, 2 Oct 2009 12:19:16 +0000 (12:19 +0000)]
Fix typo.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83246
91177308 -0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Fri, 2 Oct 2009 10:32:51 +0000 (10:32 +0000)]
FileCheckize test case.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83244
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Fri, 2 Oct 2009 04:52:12 +0000 (04:52 +0000)]
Don't update the struct alignment when adding fields to a packed struct. Fixes PR5118.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83235
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mike Stump [Fri, 2 Oct 2009 02:30:50 +0000 (02:30 +0000)]
More magic pixie dust.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83232
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mike Stump [Fri, 2 Oct 2009 02:23:37 +0000 (02:23 +0000)]
Fix up debug information for block pointers a bit more.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83231
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Fri, 2 Oct 2009 02:15:20 +0000 (02:15 +0000)]
When building constant structs, check if the resulting LLVM struct will be bigger than the record layout size and use a packed struct if that's the case. Fixes PR5108.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83230
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Thu, 1 Oct 2009 23:51:25 +0000 (23:51 +0000)]
Make sure to free the explicit template arguments provided for an
explicit instantiation. Also, tighten up reference-count checking to
help catch these issues earlier. Fixes PR5069.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83225
91177308 -0d34-0410-b5e6-
96231b3b80d8
Steve Naroff [Thu, 1 Oct 2009 23:46:04 +0000 (23:46 +0000)]
- Remove Sema::FindMethodInNestedImplementations().
- Add ObjCInterfaceDecl::lookupPrivateInstanceMethod().
- Convert clients.
No functionality change - One less method in Sema:-)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83224
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Thu, 1 Oct 2009 23:25:31 +0000 (23:25 +0000)]
When the return type of a function is dependent, don't perform any
of the flow-control checks for falling off the end of a function,
since the return type may instantiate to void. Similarly, if a
return statement has an expression and the return type of the function
is void, don't complain if the expression is type-dependent, since
that type could instantiate to void.
Fixes PR5071.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83222
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mike Stump [Thu, 1 Oct 2009 22:29:41 +0000 (22:29 +0000)]
Implement a FIXME. This improves codegen just a tad.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83221
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Thu, 1 Oct 2009 22:10:15 +0000 (22:10 +0000)]
enumerator value of 0 is not a null pointer constant for
deciding const of null pointer conversion. Fixes PR5086.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83217
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Thu, 1 Oct 2009 20:44:19 +0000 (20:44 +0000)]
CodeGen may see out-of-line declarations of the various special member
functions when they are explicitly declared, e.g., via a function
template specialization or explicit template instantiation
declaration. Don't try to synthesize bodies for the special member
functions in this case; rather, check whether we have an implicit
declaration and, if so, synthesize the appropriate function
body. Fixes PR5084.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83212
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Thu, 1 Oct 2009 20:39:51 +0000 (20:39 +0000)]
Patch to implement static casting which requires one
user-defined type conversion. Fixes PR5040.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83211
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Thu, 1 Oct 2009 20:30:46 +0000 (20:30 +0000)]
Set __EXCEPTIONS by checking on darwin's triple.
Patch by Rafael Espindola.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83209
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Thu, 1 Oct 2009 17:31:50 +0000 (17:31 +0000)]
Fix bad grammar in static analyzer diagnostic. Reported by Robert Purves!
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83204
91177308 -0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Thu, 1 Oct 2009 13:33:33 +0000 (13:33 +0000)]
Move the "needs exception support" logic to clang. This also fixes
-fno-exceptions in C++ code. We used to always define __EXCEPTIONS in
C++.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83199
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Thu, 1 Oct 2009 05:49:51 +0000 (05:49 +0000)]
Fix a lame regression in IR gen for C++ delete expressions. PR5102
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83195
91177308 -0d34-0410-b5e6-
96231b3b80d8
Steve Naroff [Thu, 1 Oct 2009 00:31:07 +0000 (00:31 +0000)]
Add support for class and protocol references.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83186
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mike Stump [Thu, 1 Oct 2009 00:27:30 +0000 (00:27 +0000)]
A couple of refinements for laying out debug information for
BlockDeclRefDecls.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83185
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Thu, 1 Oct 2009 00:25:31 +0000 (00:25 +0000)]
Anonymous namespaces, sema + codegen. A lot of semantics are still broken,
apparently because using directives aren't quite working correctly.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83184
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Wed, 30 Sep 2009 22:13:51 +0000 (22:13 +0000)]
Improve template argument deduction in the case where the parameter
type is a template-id (e.g., basic_ostream<CharT, Traits>) and the
argument type is a class that has a derived class matching the
parameter type. Previously, we were giving up on template argument
deduction too early.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83177
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Wed, 30 Sep 2009 21:46:01 +0000 (21:46 +0000)]
When overload resolution fails for an overloaded operator, show the
overload candidates (but not the built-in ones). We still rely on the
underlying built-in semantic analysis to produce the initial
diagnostic, then print the candidates following that diagnostic.
One side advantage of this approach is that we can perform more validation
of C++'s operator overloading with built-in candidates vs. the
semantic analysis for those built-in operators: when there are no
viable candidates, we know to expect an error from the built-in
operator handling code. Otherwise, we are not modeling the built-in
semantics properly within operator overloading. This is checked as:
assert(Result.isInvalid() &&
"C++ binary operator overloading is missing
candidates!");
if (Result.isInvalid())
PrintOverloadCandidates(CandidateSet, /*OnlyViable=*/false);
The assert() catches cases where we're wrong in a +Asserts build. The
"if" makes sure that, if this happens in a production clang
(-Asserts), we still build the proper built-in operator and continue
on our merry way. This is effectively what happened before this
change, but we've added the assert() to catch more flies.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83175
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Wed, 30 Sep 2009 21:39:51 +0000 (21:39 +0000)]
Tweak CHECK lines to eliminate a failure on i686-apple-darwin10
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83173
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Wed, 30 Sep 2009 21:23:30 +0000 (21:23 +0000)]
Issue good diagnostics when initializing a refernce type with
a bad initializer. Fixes pr4274.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83169
91177308 -0d34-0410-b5e6-
96231b3b80d8
Tanya Lattner [Wed, 30 Sep 2009 20:47:43 +0000 (20:47 +0000)]
Add an error for function parameters that have a qualified address space since this is not allowed by the embedded c extension spec.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83165
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 30 Sep 2009 20:20:06 +0000 (20:20 +0000)]
fix line #'s
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83162
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 30 Sep 2009 20:19:10 +0000 (20:19 +0000)]
add some more popular examples, color code warning: and error: like the command line.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83161
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 30 Sep 2009 19:55:07 +0000 (19:55 +0000)]
Convert from nonportable grep to filecheck, patch by John Thompson
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83158
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Wed, 30 Sep 2009 18:32:57 +0000 (18:32 +0000)]
Update C++ status page
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83157
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Wed, 30 Sep 2009 17:46:20 +0000 (17:46 +0000)]
Note location of operators caused the circularity.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83153
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Wed, 30 Sep 2009 17:10:29 +0000 (17:10 +0000)]
<rdar://problem/
7263113 > Make clang produce gcc's objc_assign_StrongCast as a result of type-cast of an ivar in assignment.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83150
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 30 Sep 2009 15:59:45 +0000 (15:59 +0000)]
update copyright.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83149
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mike Stump [Wed, 30 Sep 2009 02:43:10 +0000 (02:43 +0000)]
Improve debugging information for BlockDeclRefExpr. WIP. Given this
scheme, we can switch the previous scheme over to using this code
path. There's a bit of simplifications yet to do as well.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83138
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Wed, 30 Sep 2009 01:30:54 +0000 (01:30 +0000)]
Spare the processors of those poor wretches who have no choice but to write
unbounded chains of operator-> delegations.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83134
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Wed, 30 Sep 2009 01:01:30 +0000 (01:01 +0000)]
Detect operator-> chains of arbitrary length. Use a terrible data structure
to strike fear into the hearts of CPUs everywhere.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83133
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Wed, 30 Sep 2009 00:19:41 +0000 (00:19 +0000)]
self-referecing operator '->' member function was causing
infinit recursion. This patch fixes it. [13.3.1.2]-p2
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83124
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Wed, 30 Sep 2009 00:03:47 +0000 (00:03 +0000)]
Find operators new/delete in base classes. FIXME -= 2;
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83119
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Tue, 29 Sep 2009 23:03:30 +0000 (23:03 +0000)]
Desugaring optimizations. Add single-step desugaring methods to all
concrete types. Use unqualified desugaring for getAs<> and sundry.
Fix a few users to either not desugar or use qualified desugar, as seemed
appropriate. Removed Type's qualified desugar method, as it was easy
to accidentally use instead of QualType's.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83116
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Tue, 29 Sep 2009 21:38:53 +0000 (21:38 +0000)]
The C++ delete expression strips cv-qualifiers from the pointed-to type. My previous fix eliminated this behavior, so bring it back again.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83113
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 21:27:32 +0000 (21:27 +0000)]
Pull TypeLocVisitor into its own header file.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83112
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 21:26:53 +0000 (21:26 +0000)]
Keep track of type references in DeclReferenceMap.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83111
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 21:26:35 +0000 (21:26 +0000)]
In ASTVisitor, call the correct base methods.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83110
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 21:26:14 +0000 (21:26 +0000)]
Fix Decl class hierarchy.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83109
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Tue, 29 Sep 2009 20:28:06 +0000 (20:28 +0000)]
13.1-p3 Overloadable declarations
Parameter declarations that differ only in the presence or absence of const and/or volatile are equivalent.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83104
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 19:58:16 +0000 (19:58 +0000)]
Resolve a source location inside the return type of a functon.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83101
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 19:45:58 +0000 (19:45 +0000)]
When pointing at a type decl reference, ASTLocation is a NamedDeclRef.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83099
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 19:45:41 +0000 (19:45 +0000)]
Resolve a source location that is inside a type declarator.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83098
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 19:45:22 +0000 (19:45 +0000)]
Introduce ObjCInterfaceLoc which provides type source information for ObjC interfaces.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83097
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 19:44:47 +0000 (19:44 +0000)]
Introduce TypedefLoc::getTypedefDecl().
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83096
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 19:44:27 +0000 (19:44 +0000)]
Modify ASTLocation and apart from being a Decl or Stmt, allow it to also be:
-A NamedDecl reference
-A TypeLoc
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83095
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 19:43:35 +0000 (19:43 +0000)]
Introduce ObjCProtocolListLoc for keeping source location information for protocol references.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83094
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 19:42:55 +0000 (19:42 +0000)]
Introduce ObjCProtocolListType type subclass.
This is used only for keeping detailed type source information for protocol references,
it should not participate in the semantics of the type system.
Its protocol list is not canonicalized.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83093
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 19:42:11 +0000 (19:42 +0000)]
Move DeclSpec::setProtocolQualifiers() out of line.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83092
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 19:41:44 +0000 (19:41 +0000)]
Keep protocol source locations when parsing protocol references.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83091
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 19:41:13 +0000 (19:41 +0000)]
Introduce Type::getTypeClassName() that returns the string associated with the TypeClass enum.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83090
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 19:40:46 +0000 (19:40 +0000)]
Introduce TypeLoc::getSourceRange().
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83089
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 19:40:20 +0000 (19:40 +0000)]
-Introduce TypeLoc::getOpaqueData()
-Make TypeLoc's constructor public.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83088
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 29 Sep 2009 19:39:53 +0000 (19:39 +0000)]
Add more const-goodness to ASTLocation.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83087
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Tue, 29 Sep 2009 18:52:10 +0000 (18:52 +0000)]
Fix truck sized thinko where Darwin/ARM toolchain didn't look for programs in
libexec, *blush*.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83086
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Tue, 29 Sep 2009 18:51:43 +0000 (18:51 +0000)]
Add a test case demonstrating a situation where we get protocol type checking
right for multiple anonymous categories.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83085
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Tue, 29 Sep 2009 18:16:17 +0000 (18:16 +0000)]
Handle C++ delete expressions when the overloaded delete operator is a
"usual deallocation function" with two arguments. CodeGen will have to
handle this case specifically, since the value for the second argument
(the size of the allocated object) may have to be computed at run
time.
Fixes the Sema part of PR4782.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83080
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Tue, 29 Sep 2009 17:31:54 +0000 (17:31 +0000)]
Fixes a nasty bug which only turned up in 32bit build of clang and
had to do with an initialized field when multiple type conversions
are ambiguous but must be treated as user defined conversion for
overload resolution purposes.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83079
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Tue, 29 Sep 2009 17:08:03 +0000 (17:08 +0000)]
Update checker build.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83074
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Tue, 29 Sep 2009 16:36:48 +0000 (16:36 +0000)]
Fix: <rdar://problem/
7261075 > [RegionStore] crash when handling load: '*((unsigned int *)"????")'
This issue was originally reported via personal email by Thomas Clement!
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83069
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Tue, 29 Sep 2009 15:13:39 +0000 (15:13 +0000)]
Make sure to flush raw_string_ostream, from John Thompson
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83066
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Tue, 29 Sep 2009 14:54:28 +0000 (14:54 +0000)]
Allow the PYTHON make variable to override the default Python when running Clang tests, from Ken Dyck.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83065
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Tue, 29 Sep 2009 14:42:43 +0000 (14:42 +0000)]
Set GNUMode only for the "gnu" language standard options, from Ken Dyck!
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83064
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Tue, 29 Sep 2009 14:38:03 +0000 (14:38 +0000)]
Slightly improve the semantics of extern templates for member functions of class templates
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83063
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Tue, 29 Sep 2009 06:35:00 +0000 (06:35 +0000)]
Fix really insidious bug in RegionStoreManager::RemoveDeadBindings()
identified with a false positive reported by Thomas Clement. This
involved doing another rewrite of
RegionStoreManager::RemoveDeadBindings(), which phrases the entire
problem of scanning for dead regions as a graph exploration problem.
It is more methodic than the previous implementation.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83053
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Tue, 29 Sep 2009 05:36:21 +0000 (05:36 +0000)]
Remove PR5061 workaround.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83046
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Tue, 29 Sep 2009 03:54:11 +0000 (03:54 +0000)]
Handle CXXMemberCallExprs that point to a static method. Fixes PR5093.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83045
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Tue, 29 Sep 2009 03:38:56 +0000 (03:38 +0000)]
Forgot test.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83044
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Tue, 29 Sep 2009 03:34:03 +0000 (03:34 +0000)]
Reapply most of r82939, but add a guard that FieldRegions and friends
are only specially treated by RegionStore::InvalidateRegion() when
their super region is also invalidated. When this isn't the case,
conjure a new symbol for a FieldRegion. Thanks to Zhongxing Xu and
Daniel Dunbar for pointing out this issue.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83043
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Tue, 29 Sep 2009 03:26:11 +0000 (03:26 +0000)]
Add an input file that includes all standard C++ headers
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83042
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Tue, 29 Sep 2009 03:13:20 +0000 (03:13 +0000)]
Handle CK_BaseToDerivedMemberPointer for member function pointers. Fixes PR5091.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83041
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Tue, 29 Sep 2009 03:12:50 +0000 (03:12 +0000)]
Revert r82939. We can only not special case FieldRegions when the super region has also been invalidated.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83040
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Tue, 29 Sep 2009 02:09:01 +0000 (02:09 +0000)]
Improve support for member function pointers.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83039
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Tue, 29 Sep 2009 01:23:39 +0000 (01:23 +0000)]
Use a switch statement in VisitCastExpr.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83038
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Tue, 29 Sep 2009 01:15:29 +0000 (01:15 +0000)]
Make hasAggregateLLVMType use positive checks.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83037
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mike Stump [Tue, 29 Sep 2009 00:50:50 +0000 (00:50 +0000)]
Fix http://llvm.org/PR5090.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83035
91177308 -0d34-0410-b5e6-
96231b3b80d8