]>
granicus.if.org Git - clang/log
Ted Kremenek [Tue, 19 Oct 2010 18:16:54 +0000 (18:16 +0000)]
Simplify lifetime management of MacroInfo objects in Preprocessor by having the Preprocessor maintain them in a linked
list of allocated MacroInfos. This requires only 1 extra pointer per MacroInfo object, and allows us to blow them
away in one place. This fixes an elusive memory leak with MacroInfos (whose exact location I couldn't still figure
out despite substantial digging).
Fixes <rdar://problem/
8361834 >.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116842
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 19 Oct 2010 18:06:49 +0000 (18:06 +0000)]
Fix up the comments for creating ParmVarDeclAbbrev to reflect reality.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116838
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 19 Oct 2010 18:06:47 +0000 (18:06 +0000)]
Minor optimization; if we have a CXXRecordDecl we can get the definition decl directly without iterating over the redeclarations.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116837
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Tue, 19 Oct 2010 18:06:43 +0000 (18:06 +0000)]
Merge headers into test/PCH/chain-cxx.cpp for convenience.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116836
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Tue, 19 Oct 2010 18:06:10 +0000 (18:06 +0000)]
Fix CMake installation of arm_neon.h
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116835
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Tue, 19 Oct 2010 17:40:53 +0000 (17:40 +0000)]
In ~Preprocessor(), also cleanup the MacroInfo objects left-over from stray "#pragma push_macro" uses. This
fixes a potential memory leak.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116826
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Tue, 19 Oct 2010 17:40:50 +0000 (17:40 +0000)]
Fix typo in comment.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116825
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Tue, 19 Oct 2010 17:19:29 +0000 (17:19 +0000)]
This patch implements Next's IRGen for -fconstant-string-class=class-name.
PR6056, //rdar: //
8564463
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116819
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Tue, 19 Oct 2010 17:17:35 +0000 (17:17 +0000)]
When marking declarations referenced within an expression (e.g.,
within a default argument), recurse into default arguments. Fixes
PR8401, a regression I introduced in r113700 while refactoring our
handling of "used" declarations in default arguments.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116817
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chandler Carruth [Tue, 19 Oct 2010 08:47:51 +0000 (08:47 +0000)]
Use CLANG_RESOURCE_DIR define if one is provided, otherwise use the default of
'../lib/clang/<version>'. Actually use '..' rather than removing the trailing
component to correctly handle paths containing '.' or symlinks in the presence
of -no-canonical-prefixes, etc. This shouldn't change any existing behavior.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116803
91177308 -0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Tue, 19 Oct 2010 06:39:49 +0000 (06:39 +0000)]
test: FileCheck'ize and document test.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116799
91177308 -0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Tue, 19 Oct 2010 06:39:39 +0000 (06:39 +0000)]
Fix Whitespace.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116798
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Tue, 19 Oct 2010 05:43:52 +0000 (05:43 +0000)]
MSVC space optimization.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116797
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Tue, 19 Oct 2010 05:23:37 +0000 (05:23 +0000)]
Petty space optimizations in ElaboratedType and DependentNameType.
Petty time optimization in TemplateTypeParmType.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116796
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Tue, 19 Oct 2010 05:01:53 +0000 (05:01 +0000)]
When instantiating a dependently-scoped friend function declaration,
we may need to complete the type before looking into it.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116795
91177308 -0d34-0410-b5e6-
96231b3b80d8
NAKAMURA Takumi [Tue, 19 Oct 2010 03:42:41 +0000 (03:42 +0000)]
lib/Headers/stddef.h: wint_t should be defined whenever <stddef.h> is included with __need_wint_t.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116794
91177308 -0d34-0410-b5e6-
96231b3b80d8
NAKAMURA Takumi [Tue, 19 Oct 2010 03:38:22 +0000 (03:38 +0000)]
test/Coverage/html-diagnostics.c: Use find(1) to glob wildcards.
MSYS cat(1) does not expand wildcards.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116793
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Tue, 19 Oct 2010 02:26:41 +0000 (02:26 +0000)]
Instantiate enclosing template parameter lists when instantiating friends.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116789
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Tue, 19 Oct 2010 01:54:45 +0000 (01:54 +0000)]
Uncomputable contexts are always records but can exist.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116787
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Tue, 19 Oct 2010 01:40:49 +0000 (01:40 +0000)]
Redirect templated friend class decls to a new Sema callback and
construct an unsupported friend when there's a friend with a templated
scope specifier. Fixes a consistency crash, rdar://problem/
8540527
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116786
91177308 -0d34-0410-b5e6-
96231b3b80d8
NAKAMURA Takumi [Tue, 19 Oct 2010 01:17:08 +0000 (01:17 +0000)]
test/Sema/return.c: Cygwin does not have _longjmp().
Although Cygwin-1.7 has _longjmp(), it would not be essential for this
to distinguish Cygwin's version with <cygwin/version.h>.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116783
91177308 -0d34-0410-b5e6-
96231b3b80d8
NAKAMURA Takumi [Tue, 19 Oct 2010 01:11:16 +0000 (01:11 +0000)]
test/Coverage/html-diagnostics.c: Do not make hit "CHECK: Dereference of null pointer" to the output itself!
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116782
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Tue, 19 Oct 2010 00:03:23 +0000 (00:03 +0000)]
Tweak code-completion result priorities, so that exact and similar
type matches have a bigger impact. The impetus for this change was
that, when initializing an enumeration value, we want enumerators of
that enumeration type to have a higher priority than, e.g., unrelated
local variables.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116774
91177308 -0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 18 Oct 2010 23:51:38 +0000 (23:51 +0000)]
We shouldn't keep track of MMX registers "needed" separately from the SSE
registers needed.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116772
91177308 -0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Mon, 18 Oct 2010 23:38:51 +0000 (23:38 +0000)]
From scratch rewrite of mm_malloc.h.
Patch by Matthew Beaumont-Gay!
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116771
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Mon, 18 Oct 2010 23:37:08 +0000 (23:37 +0000)]
tests: Force triple to avoid limited precision warning on win32.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116770
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Mon, 18 Oct 2010 23:36:05 +0000 (23:36 +0000)]
"Fix" bogus idempotent operations warning due to loop unrolling not unrolling enough loops to show that an invariant
doesn't hold. This fix is to increase the loop unrolling count to 4, which experiments show doesn't typically impact
analysis time. The real fix is to modify the IdempotentOperationsChecker to suppress warnings where an analysis point
could be preceded by a point where we gave up due to loop unrolling.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116769
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Mon, 18 Oct 2010 22:49:46 +0000 (22:49 +0000)]
Driver: Reject -fasm-blocks except on X86 (where we just ignore it, since
passing it is very prevalent in some circles).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116761
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Mon, 18 Oct 2010 22:36:15 +0000 (22:36 +0000)]
Driver/IA: Accept and ignore -force_cpusubtype_ALL, as in 'clang -c
-Wa,-force_cpusubtype_ALL t.c'.
- Tweaks -Wa, and -Xassembler handling to only accept an explicit short list of
arguments and give an obvious unsupported error on others.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116759
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Mon, 18 Oct 2010 22:08:36 +0000 (22:08 +0000)]
Driver/Darwin: Forward -ObjC when linking, which may be needed when using static
libraries with Objective-C code.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116758
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Mon, 18 Oct 2010 22:01:46 +0000 (22:01 +0000)]
Fix the translation of the PCC_ForInit code-completion context for
C++/C99/Objective-C, so that we properly include types. This fix
affects global caching of code-completion results; without caching,
the behavior was already correct.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116757
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Mon, 18 Oct 2010 21:34:55 +0000 (21:34 +0000)]
Provide code completion for types after the '^' that starts a block
literal.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116754
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Mon, 18 Oct 2010 21:28:44 +0000 (21:28 +0000)]
Fix some bugs in local class mangling brought up in PR8355.
Patch by Richard Smith!
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116752
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Mon, 18 Oct 2010 21:05:04 +0000 (21:05 +0000)]
Introduce code completion results for Objective-C methods, both when
declaring methods and when sending messages to them, by bringing all
of the selector into TypedCheck chunks in the completion result. This
way, we can improve the sorting of these results to account for the
full selector name rather than just the first chunk.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116746
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Mon, 18 Oct 2010 19:20:11 +0000 (19:20 +0000)]
Read/write declaration attributes from/to PCH properly. Embed them in the declaration block instead of trying to create another block.
The new block was messing with the assumption that after decls block comes the stmts block.
Fixes http://llvm.org/PR8406
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116737
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Mon, 18 Oct 2010 19:20:05 +0000 (19:20 +0000)]
Merge header & cpp for test/PCH/attrs.c - more convenient to keep the tests in one source file.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116736
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Mon, 18 Oct 2010 18:21:28 +0000 (18:21 +0000)]
When providing code completions of Objective-C method declarations
(after - or +), always traverse superclasses and all categories. The
programmer may want to complete a method from *anywhere*.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116723
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Mon, 18 Oct 2010 17:51:06 +0000 (17:51 +0000)]
patch fixes class names missing from method names in debug information for
synthesized property. // rdar: //
8498026
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116717
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Mon, 18 Oct 2010 16:24:27 +0000 (16:24 +0000)]
Implement the first half of [dcl.attr.override]p6.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116709
91177308 -0d34-0410-b5e6-
96231b3b80d8
Francois Pichet [Mon, 18 Oct 2010 15:01:13 +0000 (15:01 +0000)]
Microsoft enum extensions. 2 things will change on -fms-extensions:
1. enum underlying type is int by default.
2. Error "enumerator value is not representable in the underlying type"is a ExtWarning
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116704
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Mon, 18 Oct 2010 14:43:21 +0000 (14:43 +0000)]
Add iteration over the preprocessor conditional stack to PreprocessorLexer
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116703
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Mon, 18 Oct 2010 14:35:28 +0000 (14:35 +0000)]
Add declarations nested in a linkage specification to the output of
-ast-print-xml, from Martin Vejnar!
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116702
91177308 -0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Mon, 18 Oct 2010 07:11:10 +0000 (07:11 +0000)]
CodeGen: Fix long double on Windows using MSVC runtime.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116700
91177308 -0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Mon, 18 Oct 2010 07:10:59 +0000 (07:10 +0000)]
Fix Whitespace.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116699
91177308 -0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 18 Oct 2010 03:41:31 +0000 (03:41 +0000)]
Reapply r116684 with fixes. The test cases needed to be updated.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116696
91177308 -0d34-0410-b5e6-
96231b3b80d8
Oscar Fuentes [Mon, 18 Oct 2010 02:25:54 +0000 (02:25 +0000)]
Do not use absolute path on the clang++ symlink.
Based on a patch by Ryuta Suzuki!
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116695
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Sun, 17 Oct 2010 23:36:12 +0000 (23:36 +0000)]
Implement [dcl.attr.override]p2 and add tests for p1 and p2.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116692
91177308 -0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Sun, 17 Oct 2010 22:47:44 +0000 (22:47 +0000)]
Add test for [dcl.attr.final]p4.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116691
91177308 -0d34-0410-b5e6-
96231b3b80d8
Oscar Fuentes [Sun, 17 Oct 2010 16:10:32 +0000 (16:10 +0000)]
Use a script for creating the clang++ executable.
The previous method used the DESTDIR environment variable at configure
time, but sometimes it is only available at install time. See PR8397.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116689
91177308 -0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Sun, 17 Oct 2010 07:58:46 +0000 (07:58 +0000)]
Temporarily revert r116684. It was causing failures with
Clang :: CodeGen/x86_32-arguments-darwin.c
Clang :: CodeGen/x86_32-arguments-linux.c
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116687
91177308 -0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Sun, 17 Oct 2010 07:38:01 +0000 (07:38 +0000)]
The "gcc.dg/compat/vector-1 -m32" test was broken after the MMX rewrite. The
function parameters weren't converted to use the correct type (x86_mmx). Add a
check, similar to the one in llvm-gcc, to see if we need the x86_mmx type for
that function parameter. If so, it coerces the type to be that.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116684
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Sat, 16 Oct 2010 17:18:07 +0000 (17:18 +0000)]
Xcode keeps modifying the project file and I don't know how to ignore the change; just commit it.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116673
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Sat, 16 Oct 2010 16:34:08 +0000 (16:34 +0000)]
Coding by inspection has its problems.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116672
91177308 -0d34-0410-b5e6-
96231b3b80d8
Gabor Greif [Sat, 16 Oct 2010 09:40:21 +0000 (09:40 +0000)]
validator
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116668
91177308 -0d34-0410-b5e6-
96231b3b80d8
Gabor Greif [Sat, 16 Oct 2010 09:29:38 +0000 (09:29 +0000)]
these items are done, afaik
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116667
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Sat, 16 Oct 2010 08:21:07 +0000 (08:21 +0000)]
objc_exception_rethrow does not take an exception argument.
rdar://problem/
8535238
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116663
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Sat, 16 Oct 2010 07:23:36 +0000 (07:23 +0000)]
Reformatting.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116662
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Sat, 16 Oct 2010 06:59:13 +0000 (06:59 +0000)]
White-listing templated-scope friend decls is a good idea, but doing it
by marking the decl invalid isn't. Make some steps towards supporting these
and then hastily shut them down at the last second by marking them as
unsupported.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116661
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Sat, 16 Oct 2010 05:04:10 +0000 (05:04 +0000)]
Revert r116656, "IRgen/Obj-C/NeXT: Fix the IR signature for
objc_exception_rethrow, so we don't...", since something is actually trying to
call this with the wrong signature (!). Unfortunately I don't understand the new
EH infrastructure well enough to fix it immediately.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116660
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Sat, 16 Oct 2010 04:10:37 +0000 (04:10 +0000)]
Add an empty robots.txt, mostly just to reduce errors in HTTP log.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116658
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Sat, 16 Oct 2010 04:08:19 +0000 (04:08 +0000)]
Add a favicon.ico, mostly just to reduce errors in HTTP log.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116657
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Sat, 16 Oct 2010 04:08:16 +0000 (04:08 +0000)]
IRgen/Obj-C/NeXT: Fix the IR signature for objc_exception_rethrow, so we don't
generate unnecessary %al clear on x86_64.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116656
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Sat, 16 Oct 2010 00:29:27 +0000 (00:29 +0000)]
Fix a rewriting bug of rewriting properties declared in
protocols. // rdar: //
8558702
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116652
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Sat, 16 Oct 2010 00:29:16 +0000 (00:29 +0000)]
Tweak scan-build to work with naked clang commands.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116651
91177308 -0d34-0410-b5e6-
96231b3b80d8
Chandler Carruth [Sat, 16 Oct 2010 00:24:52 +0000 (00:24 +0000)]
Not really sure how this worked, but it seems like a clear typo. =]
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116650
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Fri, 15 Oct 2010 23:53:28 +0000 (23:53 +0000)]
Allow list-initialization of a local variable of class type with a
flexible array member, so long as the flexibility array member is
either not initialized or is initialized with an empty initializer
list. Fixes <rdar://problem/
8540437 >.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116647
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Fri, 15 Oct 2010 23:23:05 +0000 (23:23 +0000)]
Disable this test again, which naturally fails on every platform except the one I'm building with
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116642
91177308 -0d34-0410-b5e6-
96231b3b80d8
Ted Kremenek [Fri, 15 Oct 2010 22:50:23 +0000 (22:50 +0000)]
Tweak retain/release checker diagnostics to specify a leak occurs because an object is not referenced later in the path,
not that it isn't referenced later in the code. Fixes <rdar://problem/
8527839 >.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116636
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Fri, 15 Oct 2010 22:42:59 +0000 (22:42 +0000)]
Check for ivar being a C++ object before attempting to
find a copy constructor/assignment operator used
in getter/setter synthesis. This removes an unintended
diagnostics and makes objc++ consistant with objective-c.
// rdar: //
8550657 .
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116631
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 15 Oct 2010 22:30:42 +0000 (22:30 +0000)]
Driver: Error on -fno-for-scope, which we have no intention of supporting.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116627
91177308 -0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Fri, 15 Oct 2010 21:43:24 +0000 (21:43 +0000)]
Report the location of the syntax error inside a macro. Fixes PR7944.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116624
91177308 -0d34-0410-b5e6-
96231b3b80d8
Francois Pichet [Fri, 15 Oct 2010 21:34:50 +0000 (21:34 +0000)]
bool bit fields are causing problems with MSVC. Replace them with unsigned bit fields.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116623
91177308 -0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Fri, 15 Oct 2010 20:54:41 +0000 (20:54 +0000)]
Mention the paragraphs in the standards which sanction TBAA.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116617
91177308 -0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Fri, 15 Oct 2010 20:26:20 +0000 (20:26 +0000)]
Use a different name for pointer types in tbaa, to be a little
more consistent with other names, and to look less like a magic name.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116616
91177308 -0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Fri, 15 Oct 2010 20:24:53 +0000 (20:24 +0000)]
Add a comment.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116615
91177308 -0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Fri, 15 Oct 2010 20:24:10 +0000 (20:24 +0000)]
Fix a typo in a comment Frits van Bommel spotted.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116614
91177308 -0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Fri, 15 Oct 2010 20:23:12 +0000 (20:23 +0000)]
Experimental TBAA support for enum types.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116613
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Fri, 15 Oct 2010 18:52:45 +0000 (18:52 +0000)]
Again, add '-include-pch' option to the driver, so it can get passed to the cc1 driver.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116608
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Fri, 15 Oct 2010 18:51:34 +0000 (18:51 +0000)]
Revert r116605, a lot more were committed by mistake.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116606
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Fri, 15 Oct 2010 18:49:01 +0000 (18:49 +0000)]
Add '-include-pch' option to the driver, so it can get passed to the cc1 driver.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116605
91177308 -0d34-0410-b5e6-
96231b3b80d8
Fariborz Jahanian [Fri, 15 Oct 2010 18:40:05 +0000 (18:40 +0000)]
Eradicate IsSuper field from ObjCImplicitSetterGetterRefExprClass
AST node. (finishing off radar
8525788 ).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116603
91177308 -0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Fri, 15 Oct 2010 18:23:36 +0000 (18:23 +0000)]
TBAA = Type Based Alias Analysis
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116599
91177308 -0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Fri, 15 Oct 2010 18:21:24 +0000 (18:21 +0000)]
Read/write to/from PCH DeclarationNameLocs, DeclarationNameInfos and QualifierInfos (rdar://
8513756 ).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116598
91177308 -0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Fri, 15 Oct 2010 18:04:46 +0000 (18:04 +0000)]
Don't leak the TBAA object.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116595
91177308 -0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Fri, 15 Oct 2010 17:52:03 +0000 (17:52 +0000)]
Add a comment about odd "signed char" incompatibility between C++ and C.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116593
91177308 -0d34-0410-b5e6-
96231b3b80d8
David Chisnall [Fri, 15 Oct 2010 17:07:39 +0000 (17:07 +0000)]
Add clang_getLocationForOffset() to libclang, for gives a source location from a character index into a file.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116587
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Fri, 15 Oct 2010 16:49:56 +0000 (16:49 +0000)]
When performing typo correction, keep track of whether the last lookup
we did was an acceptable lookup. If it is, then we can re-use that
lookup result. If it isn't, we have to perform the lookup again. This
is almost surely the cause behind the mysterious typo.m failures on
some builders; we were getting the wrong lookup results returned.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116586
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 15 Oct 2010 15:28:09 +0000 (15:28 +0000)]
Disable type.m while failures are investigated.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116577
91177308 -0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 15 Oct 2010 15:13:02 +0000 (15:13 +0000)]
Make test more consistent.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116576
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Fri, 15 Oct 2010 13:35:25 +0000 (13:35 +0000)]
When we're in the context of an Objective-C message send's receiver,
typo correction prefers "super" over other, equivalent completions. I
believe this will fix the regression on the buildbot.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116574
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Fri, 15 Oct 2010 13:21:21 +0000 (13:21 +0000)]
Diagnose C++ [class.mem]p13-14, where a class member has the same name
as the class itself. Fixes PR7082.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116573
91177308 -0d34-0410-b5e6-
96231b3b80d8
Gabor Greif [Fri, 15 Oct 2010 08:48:51 +0000 (08:48 +0000)]
zap trailing whitespace
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116572
91177308 -0d34-0410-b5e6-
96231b3b80d8
Gabor Greif [Fri, 15 Oct 2010 08:44:44 +0000 (08:44 +0000)]
testcase for http://llvm.org/PR8371 of my last commit, r116570
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116571
91177308 -0d34-0410-b5e6-
96231b3b80d8
Gabor Greif [Fri, 15 Oct 2010 08:26:25 +0000 (08:26 +0000)]
fix http://llvm.org/PR8371 in the straightforward way, also adding a comment
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116570
91177308 -0d34-0410-b5e6-
96231b3b80d8
Abramo Bagnara [Fri, 15 Oct 2010 07:51:18 +0000 (07:51 +0000)]
Treat __extension__ like ParenExpr.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116569
91177308 -0d34-0410-b5e6-
96231b3b80d8
Craig Silverstein [Fri, 15 Oct 2010 06:51:01 +0000 (06:51 +0000)]
Recurse on a TypeLoc rather than a Type for TypedefDecl, now that the
typloc information is available (I don't think it was, originally).
Submitted as a 'trivial' change.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116568
91177308 -0d34-0410-b5e6-
96231b3b80d8
John McCall [Fri, 15 Oct 2010 04:57:14 +0000 (04:57 +0000)]
Death to blocks, or at least the word "block" in one particular obnoxiously
ambiguous context.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116567
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Fri, 15 Oct 2010 01:21:46 +0000 (01:21 +0000)]
Don't complain about a variable within a linkage-specification that is
initialized. Fixes PR7076.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116553
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Fri, 15 Oct 2010 01:15:58 +0000 (01:15 +0000)]
When we are missing the ',' or '>' to terminate a template parameter
list, complain about it! Fixes PR7053.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116551
91177308 -0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Fri, 15 Oct 2010 00:50:56 +0000 (00:50 +0000)]
Add builtin conditional operator candidates for scoped enumeration
types, from Alp Toker! Fixes PR8344.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116549
91177308 -0d34-0410-b5e6-
96231b3b80d8