]>
granicus.if.org Git - clang/log
Douglas Gregor [Fri, 11 Dec 2009 23:47:56 +0000 (23:47 +0000)]
Switch the Emacs clang-completion-mode over to clang -cc1
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91185
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 11 Dec 2009 23:35:10 +0000 (23:35 +0000)]
Tests: Stop looking for clang-cc, we don't need it.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91183
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Fri, 11 Dec 2009 23:31:21 +0000 (23:31 +0000)]
Fix build.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91182
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Fri, 11 Dec 2009 23:23:22 +0000 (23:23 +0000)]
Improve diagnostics for malformed delete operator function declarations.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91180
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 11 Dec 2009 23:22:52 +0000 (23:22 +0000)]
scan-build: when the build command is 'make', override the CC and CXX options by passing them as arguments to make. This fixes <rdar://problem/
6790224 >.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91179
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 11 Dec 2009 23:17:03 +0000 (23:17 +0000)]
Update a few more docs references to clang-cc.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91178
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 11 Dec 2009 23:12:52 +0000 (23:12 +0000)]
Remove more old references to clang-cc.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91177
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 11 Dec 2009 23:04:35 +0000 (23:04 +0000)]
Update docs/comments/utils/examples to refer to clang -cc1 instead of clang-cc.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91176
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 11 Dec 2009 23:00:49 +0000 (23:00 +0000)]
Driver: Switch to using "clang" "-cc1" instead of "clang-cc".
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91174
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 11 Dec 2009 22:52:03 +0000 (22:52 +0000)]
Tests: Change substitution to automagically use 'clang -cc1' instead of 'clang-cc'. I still plan to eventually rewrite the tests to clarify the magic (I will probably actually rewrite them to %clang so it is more obvious this is a variable that gets substituted).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91173
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 11 Dec 2009 22:44:53 +0000 (22:44 +0000)]
Convert scan-build and ccc-analyzer over to using 'clang -cc1' instead of using 'clang-cc'.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91172
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Fri, 11 Dec 2009 22:40:48 +0000 (22:40 +0000)]
Patch to allow C-style cast from 'void *' to block pointer type.
(fixes radar
7465023 ).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91171
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 11 Dec 2009 22:20:12 +0000 (22:20 +0000)]
Implement clang -cc1.
- I apologize for the link time horrors, my goal is to kill off clang-cc in fairly short order.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91170
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Fri, 11 Dec 2009 21:50:11 +0000 (21:50 +0000)]
StmtDumper::VisitUnresolvedLookupExpr
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91163
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Fri, 11 Dec 2009 21:23:13 +0000 (21:23 +0000)]
Consider conversion of objective-c pointer to 'bool' a
valid standard conversion to match g++'s behaviour.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91157
91177308 -0d34-0410-b5e6-
96231b3b80d8
Eli Friedman [Fri, 11 Dec 2009 21:23:03 +0000 (21:23 +0000)]
Fix for PR5714: make sure globals that will be modified aren't marked const.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91156
91177308 -0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Fri, 11 Dec 2009 21:09:27 +0000 (21:09 +0000)]
Switch PathDiagnostic to StringRef.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91155
91177308 -0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Fri, 11 Dec 2009 20:53:46 +0000 (20:53 +0000)]
Fix two typos.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91154
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Fri, 11 Dec 2009 20:51:23 +0000 (20:51 +0000)]
Reorganize testcase.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91153
91177308 -0d34-0410-b5e6-
96231b3b80d8
Eli Friedman [Fri, 11 Dec 2009 20:48:18 +0000 (20:48 +0000)]
Fix linkage of type info and vtable for classes without linkage.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91152
91177308 -0d34-0410-b5e6-
96231b3b80d8
Eli Friedman [Fri, 11 Dec 2009 20:21:38 +0000 (20:21 +0000)]
Make sure mangling doesn't crash in another case. Add some more tests.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91149
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Fri, 11 Dec 2009 20:04:54 +0000 (20:04 +0000)]
Don't enter a new scope for a namespace-qualified declarator unless we're
in a file context. In well-formed code, only happens with friend functions.
Fixes PR 5760.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91146
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Fri, 11 Dec 2009 19:06:04 +0000 (19:06 +0000)]
When code completion of an overload set fails, produce results for ordinary name lookup instead.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91141
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Fri, 11 Dec 2009 18:44:16 +0000 (18:44 +0000)]
Add a function's cv-qualifiers to the code-completion results as an
informative chunk.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91139
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Fri, 11 Dec 2009 18:28:39 +0000 (18:28 +0000)]
Teach code completion to instantiate templates when it needs to
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91138
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Fri, 11 Dec 2009 18:14:22 +0000 (18:14 +0000)]
Member function templates can occur after . or ->
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91137
91177308 -0d34-0410-b5e6-
96231b3b80d8
Eli Friedman [Fri, 11 Dec 2009 18:00:57 +0000 (18:00 +0000)]
Fix for PR5706: let mangleName deal with mangling names without identifiers
correctly.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91136
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Fri, 11 Dec 2009 17:31:05 +0000 (17:31 +0000)]
Tweak code-completion results by suppressing class template
specializations and class template partial specializations (they're
never named directly). Also, member access expressions only refer to
value declarations (fields, functions, enumerators, etc.) and
Objective-C property declarations; filter out everything else.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91133
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Fri, 11 Dec 2009 17:01:29 +0000 (17:01 +0000)]
XFAIL this for now, fixing linkage bugs causes the order of globals to change. Will fix later today.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91130
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Fri, 11 Dec 2009 16:41:51 +0000 (16:41 +0000)]
Move info vectors and add assertions in preparation of moving the vector directly into RTTIBuilder.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91129
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Fri, 11 Dec 2009 16:37:06 +0000 (16:37 +0000)]
Use GetAddrOfRTTI when getting the RTTI pointer for a base class.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91127
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Fri, 11 Dec 2009 16:18:54 +0000 (16:18 +0000)]
Class template (partial) specializations should not show up in code completion results
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91125
91177308 -0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Fri, 11 Dec 2009 13:33:18 +0000 (13:33 +0000)]
Random string-related cleanups.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91119
91177308 -0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Fri, 11 Dec 2009 13:26:32 +0000 (13:26 +0000)]
Use StringRef.getAsInteger instead of temporary string + strtol. No intended functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91118
91177308 -0d34-0410-b5e6-
96231b3b80d8
Eli Friedman [Fri, 11 Dec 2009 09:26:29 +0000 (09:26 +0000)]
Move the code for converting a member pointer to a bool so that it is usable
for logical not.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91112
91177308 -0d34-0410-b5e6-
96231b3b80d8
Eli Friedman [Fri, 11 Dec 2009 07:36:43 +0000 (07:36 +0000)]
Fix for PR5718: implement equality comparisons for member function pointers.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91108
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 11 Dec 2009 06:43:27 +0000 (06:43 +0000)]
Enhance understanding of VarRegions referenced by a block whose declarations are outside the current stack frame. Fixes <rdar://problem/
7462324 >.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91107
91177308 -0d34-0410-b5e6-
96231b3b80d8
Zhongxing Xu [Fri, 11 Dec 2009 03:09:01 +0000 (03:09 +0000)]
Completely evaluate malloc/free in MallocChecker.cpp.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91100
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Fri, 11 Dec 2009 02:55:56 +0000 (02:55 +0000)]
Test member template using hiding.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91099
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Fri, 11 Dec 2009 02:46:30 +0000 (02:46 +0000)]
Improve linkage of RTTI data structures. Introduce CodeGenModule::GetAddrOfRTTI which figures out the right linkage of the RTTI information for the given type and whether it should be defined or not. I will migrate clients over to GetAddrOfRTTI in subsequent commits (with tests).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91098
91177308 -0d34-0410-b5e6-
96231b3b80d8
Eli Friedman [Fri, 11 Dec 2009 02:42:07 +0000 (02:42 +0000)]
Fix a recent regression from the initialization changes.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91097
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Fri, 11 Dec 2009 02:33:26 +0000 (02:33 +0000)]
Check if the target of a using decl is already declared in this scope before
doing any of the other redeclaration checks. We were missing a few cases.
Fixes PR 5752.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91096
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Fri, 11 Dec 2009 02:10:03 +0000 (02:10 +0000)]
Implement access declarations. Most of the work here is parsing them, which
is difficult because they're so terribly, terribly ambiguous.
We implement access declarations in terms of using declarations, which is
quite reasonable. However, we should really persist the access/using
distinction in the AST and use the appropriate name in diagnostics. This
isn't a priority, so I'll just file a PR and hope someone else does it. :)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91095
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 11 Dec 2009 01:52:50 +0000 (01:52 +0000)]
Give the "cannot pass object of non-POD type 'class C' through variadic constructor; call will abort at runtime" warning a -W flag (non-pod-varargs) and default it being an error by default. There is no good reason to allow users to get bitten by this sort of thing by default.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91094
91177308 -0d34-0410-b5e6-
96231b3b80d8
Eli Friedman [Fri, 11 Dec 2009 01:34:50 +0000 (01:34 +0000)]
Fix the handling of dependent enums per C++ DR 502.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91089
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Fri, 11 Dec 2009 01:27:37 +0000 (01:27 +0000)]
Use named flags in RTTIBuilder::BuildPointerType.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91088
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Fri, 11 Dec 2009 01:00:09 +0000 (01:00 +0000)]
When extending the lifetime of a temporary, make sure to emit a branch to the cleanup exit block. This fixes a broken module error in LLVMCConfigurationEmitter.cpp.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91086
91177308 -0d34-0410-b5e6-
96231b3b80d8
Zhongxing Xu [Fri, 11 Dec 2009 00:55:44 +0000 (00:55 +0000)]
Use 'class' instead of 'struct'.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91085
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Fri, 11 Dec 2009 00:32:37 +0000 (00:32 +0000)]
When an exception needs to be freed by calling __cxa_exception_free, make sure to stash away the exception pointer somewhere.
This fixes an "Instruction does not dominate all uses!" verification error when compiling TableGen.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91084
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 11 Dec 2009 00:27:30 +0000 (00:27 +0000)]
Remove this test for now, it is flaky.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91083
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 11 Dec 2009 00:27:20 +0000 (00:27 +0000)]
FileManager: Do not cache failed stats, it is easy to construct common
inconsistent situations if we do, and they are not important for PCH performance
(which currently only needs the stats to construct the initial FileManager
entries).
- No test case, sorry, the machinations are too involved.
This occurs when, for example, the build makes a PCH file and has a header map
or a -I for a directory that does not yet exist. It is possible we will cache
the negative stat on that directory, and then in the build we will never find
header files inside that dir.
For PCH we don't need these stats anyway for performance, so this also makes PCH
files smaller w/ no loss. I hope to eventually eliminate the stat cache
entirely.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91082
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Fri, 11 Dec 2009 00:26:36 +0000 (00:26 +0000)]
Patch to fix a crash trying to access a category name in
objective-c++ mode and also removed dead-code in this area.
(fixes radar
7456710 ).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91081
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mike Stump [Fri, 11 Dec 2009 00:10:15 +0000 (00:10 +0000)]
Testcase for recent checkin.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91080
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mike Stump [Fri, 11 Dec 2009 00:04:56 +0000 (00:04 +0000)]
Implement just a bit more of inline assembly.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91079
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mike Stump [Fri, 11 Dec 2009 00:02:10 +0000 (00:02 +0000)]
Fix spacing.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91078
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mike Stump [Thu, 10 Dec 2009 22:57:48 +0000 (22:57 +0000)]
Don't complain about falling off the end of a function with an asm
block, if the function is supposed to return a value as we don't know
exactly what the asm code does.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91073
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Thu, 10 Dec 2009 22:46:19 +0000 (22:46 +0000)]
clang_getCompletionChunkText() will treat optional strings as empty text blocks
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91072
91177308 -0d34-0410-b5e6-
96231b3b80d8
Eli Friedman [Thu, 10 Dec 2009 22:40:32 +0000 (22:40 +0000)]
Support unary type traits in a scalar context. Not that I've actually seen
this construct, but might as well for completeness.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91071
91177308 -0d34-0410-b5e6-
96231b3b80d8
Eli Friedman [Thu, 10 Dec 2009 22:29:29 +0000 (22:29 +0000)]
Clean up enum constants so that they're finally sane. Fixes PR3173 and a
recently introduced crash.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91070
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Thu, 10 Dec 2009 22:25:34 +0000 (22:25 +0000)]
Make sure that explicitly instantiated functions get the right linkage.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91069
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Thu, 10 Dec 2009 22:08:55 +0000 (22:08 +0000)]
Beef up Clang-on-LLVM testing a bit, by making LLVM-Syntax recursive
(since we now parse all of the headers appropriately) and teaching
LLVM-Code-Syntax about the extra paths needed to parse the backends.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91068
91177308 -0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Thu, 10 Dec 2009 21:50:21 +0000 (21:50 +0000)]
Privatize class members.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91067
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Thu, 10 Dec 2009 21:17:25 +0000 (21:17 +0000)]
Actually try to trigger the last diagnostic in the declaration-collision test case.
Surprisingly, we *do* diagnose one of them. Since we don't really track scopes into
instantiation, this has to signal some kind of bug.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91063
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Thu, 10 Dec 2009 20:57:43 +0000 (20:57 +0000)]
No need to add -x objecitve-c++
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91060
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Thu, 10 Dec 2009 20:46:08 +0000 (20:46 +0000)]
Add support for finding composite type of twp objective-c pointers
in objective-c++ mode.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91059
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Thu, 10 Dec 2009 19:51:03 +0000 (19:51 +0000)]
Improve the diagnostic when a new declaration conflicts with a using shadow
declaration. Rename note_using_decl to note_using, which is possibly less confusing.
Add a test for non-class-scope using decl collisions and be sure to note the case
we can't diagnose yet.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91057
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Thu, 10 Dec 2009 19:47:41 +0000 (19:47 +0000)]
Move composite type finding of two objective-c expressions
into its own helper method. No change in functionality.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91056
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Thu, 10 Dec 2009 18:13:52 +0000 (18:13 +0000)]
Implement C++ DR437, which involves exception-specifications that name
a type currently being defined, from Nicola Gigante!
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91052
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Thu, 10 Dec 2009 17:56:55 +0000 (17:56 +0000)]
Move initialization via initializer list over to InitializationSequences.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91050
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Thu, 10 Dec 2009 09:41:52 +0000 (09:41 +0000)]
Implement redeclaration checking and hiding semantics for using declarations. There
are a couple of O(n^2) operations in this, some analogous to the usual O(n^2)
redeclaration problem and some not. In particular, retroactively removing
shadow declarations when they're hidden by later decls is pretty unfortunate.
I'm not yet convinced it's worse than the alternative, though.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91045
91177308 -0d34-0410-b5e6-
96231b3b80d8
Eli Friedman [Thu, 10 Dec 2009 08:54:47 +0000 (08:54 +0000)]
Fix for PR5515: allow "merging" array bounds both forwards and backwards.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91044
91177308 -0d34-0410-b5e6-
96231b3b80d8
Eli Friedman [Thu, 10 Dec 2009 08:51:23 +0000 (08:51 +0000)]
Test for r90950.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91043
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Thu, 10 Dec 2009 03:14:39 +0000 (03:14 +0000)]
Mangle static variables inside Objective-C methods in Objective-C++. We currently mangle them the same way as gcc does.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91042
91177308 -0d34-0410-b5e6-
96231b3b80d8
Eli Friedman [Thu, 10 Dec 2009 02:21:21 +0000 (02:21 +0000)]
Get rid of static variable.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91041
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 10 Dec 2009 02:08:07 +0000 (02:08 +0000)]
If we enter parens, colons can become un-sacred, allowing us to emit
a better diagnostic in the second example.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91040
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 10 Dec 2009 02:02:58 +0000 (02:02 +0000)]
fix a more evil case of : / :: confusion arising in ?:.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91039
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 10 Dec 2009 01:59:24 +0000 (01:59 +0000)]
fix incorrect parsing of bitfields pointed out by Doug. I chose
to use ColonProtectionRAIIObject in the C codepath even though it
won't matter for consistency.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91037
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Thu, 10 Dec 2009 01:58:33 +0000 (01:58 +0000)]
Actually store the pointer into the global variable, spotted by Eli.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91036
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mike Stump [Thu, 10 Dec 2009 01:52:30 +0000 (01:52 +0000)]
Setup cleanup on eh edge out of the construction of the cleanup object
during throw to deallocate the exception object. WIP.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91035
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 10 Dec 2009 01:38:15 +0000 (01:38 +0000)]
minimal fix for PR5743
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91032
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Thu, 10 Dec 2009 01:05:11 +0000 (01:05 +0000)]
Handle emitting static variables that have reference type.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91027
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Thu, 10 Dec 2009 00:57:45 +0000 (00:57 +0000)]
Separate generating code for static variables and global variables.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91026
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Thu, 10 Dec 2009 00:57:18 +0000 (00:57 +0000)]
Fix tabs.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91025
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 10 Dec 2009 00:45:15 +0000 (00:45 +0000)]
Second half of r91023, saving files is good.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91024
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 10 Dec 2009 00:44:03 +0000 (00:44 +0000)]
move GreaterThanIsOperatorScope into RAIIObjectsForParser. Add some more
TODOs for other classes that could be moved out of Parser.h. I don't plan
to do these in the near term though.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91023
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 10 Dec 2009 00:38:54 +0000 (00:38 +0000)]
fix PR5740: a colon is sacred when parsing case statement expressions!
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91016
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 10 Dec 2009 00:37:13 +0000 (00:37 +0000)]
rename testcase
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91015
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 10 Dec 2009 00:32:41 +0000 (00:32 +0000)]
refactor the 'ColonIsSacred' argument to ParseOptionalCXXScopeSpecifier
to be a bool in Parser that is twiddled by the ColonProtectionRAIIObject
class. No functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91014
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Thu, 10 Dec 2009 00:30:05 +0000 (00:30 +0000)]
Move more decl related functions to CGDeclCXX.cpp
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91012
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 10 Dec 2009 00:21:05 +0000 (00:21 +0000)]
rename ExtensionRAIIObject.h -> RAIIObjectsForParser.h
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91008
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Thu, 10 Dec 2009 00:16:00 +0000 (00:16 +0000)]
Add CGDeclCXX.cpp and move EmitCXXGlobalVarDeclInit there.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91006
91177308 -0d34-0410-b5e6-
96231b3b80d8
Nuno Lopes [Thu, 10 Dec 2009 00:07:02 +0000 (00:07 +0000)]
spread 'const' love to some variables. this considerably reduces the amount of dirty data around.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91002
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mike Stump [Thu, 10 Dec 2009 00:06:18 +0000 (00:06 +0000)]
Fixup spacing.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91001
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mike Stump [Thu, 10 Dec 2009 00:05:14 +0000 (00:05 +0000)]
Fix spacing.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91000
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mike Stump [Thu, 10 Dec 2009 00:02:42 +0000 (00:02 +0000)]
Ensure we only generate one terminate handler.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90998
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mike Stump [Wed, 9 Dec 2009 23:52:09 +0000 (23:52 +0000)]
Remove obsolete FIXME and some dead fallback code.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90997
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mike Stump [Wed, 9 Dec 2009 23:49:53 +0000 (23:49 +0000)]
Add terminate handler to cleanups on exceptional edges.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90996
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Wed, 9 Dec 2009 23:35:29 +0000 (23:35 +0000)]
Code gen for ObjCIsaExpr AST used as lvalue.
(fixes radar
7457534 ).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90995
91177308 -0d34-0410-b5e6-
96231b3b80d8
Mike Stump [Wed, 9 Dec 2009 23:31:35 +0000 (23:31 +0000)]
Add terminate handler for copy constructors for thrown objects. WIP.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90994
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Wed, 9 Dec 2009 23:29:55 +0000 (23:29 +0000)]
Fix null dereference in OSAtomicChecker and special case SymbolicRegions. We still aren't handling them correctly; I've added to failing test cases to test/Analysis/NSString-failed-cases.m that should pass and then be merged in to test/Analysis/NSString.m.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90993
91177308 -0d34-0410-b5e6-
96231b3b80d8