]> granicus.if.org Git - clang/log
clang
12 years agoPlace "use @dynamic or provide a method implementation" warnings under a -W flag.
Ted Kremenek [Tue, 29 Nov 2011 19:18:47 +0000 (19:18 +0000)]
Place "use @dynamic or provide a method implementation" warnings under a -W flag.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145418 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoTeach the module import mechanism how to rebuild modules expressed via
Douglas Gregor [Tue, 29 Nov 2011 19:06:37 +0000 (19:06 +0000)]
Teach the module import mechanism how to rebuild modules expressed via
module map, rather than assuming that there is an umbrella
header. This allows us to automatically build umbrella-less modules.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145415 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoStart refactoring to use module maps when rebuilding a module
Douglas Gregor [Tue, 29 Nov 2011 18:31:39 +0000 (18:31 +0000)]
Start refactoring to use module maps when rebuilding a module
on-the-fly. No functionality change.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145414 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoInitialize NumWarningsInPreamble in ASTUnit's constructor, for safety.
Argyrios Kyrtzidis [Tue, 29 Nov 2011 18:18:33 +0000 (18:18 +0000)]
Initialize NumWarningsInPreamble in ASTUnit's constructor, for safety.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145412 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoExpose the printing of module maps as part of the ModuleMap::Module
Douglas Gregor [Tue, 29 Nov 2011 18:17:59 +0000 (18:17 +0000)]
Expose the printing of module maps as part of the ModuleMap::Module
interface. No functionality change.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145411 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoThe cheap version of getName() is sufficient here.
Benjamin Kramer [Tue, 29 Nov 2011 14:46:55 +0000 (14:46 +0000)]
The cheap version of getName() is sufficient here.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145399 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoPreserve constness.
Benjamin Kramer [Tue, 29 Nov 2011 12:31:20 +0000 (12:31 +0000)]
Preserve constness.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145397 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoSilence GCC warnings, RefCountedBase is meant to be default-initialized here.
Benjamin Kramer [Tue, 29 Nov 2011 11:31:35 +0000 (11:31 +0000)]
Silence GCC warnings, RefCountedBase is meant to be default-initialized here.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145396 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd fix-it to remove 'typedef' from function template definitions. Such a token
Richard Smith [Tue, 29 Nov 2011 09:09:06 +0000 (09:09 +0000)]
Add fix-it to remove 'typedef' from function template definitions. Such a token
was probably meant to be 'typename', which we will have already suggested if it
is appropriate.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145395 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFix leaking of LexedMethod objects created for caching objc method definitions tokens
Argyrios Kyrtzidis [Tue, 29 Nov 2011 08:14:54 +0000 (08:14 +0000)]
Fix leaking of LexedMethod objects created for caching objc method definitions tokens
for late parsing.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145394 91177308-0d34-0410-b5e6-96231b3b80d8

12 years ago[libclang] Fix leak in clang_indexSourceFile_Impl
Argyrios Kyrtzidis [Tue, 29 Nov 2011 08:14:50 +0000 (08:14 +0000)]
[libclang] Fix leak in clang_indexSourceFile_Impl

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145393 91177308-0d34-0410-b5e6-96231b3b80d8

12 years ago[Win32] Catch exceptions (eg. segfault) on waiting for invoked clang from the driver.
NAKAMURA Takumi [Tue, 29 Nov 2011 07:47:04 +0000 (07:47 +0000)]
[Win32] Catch exceptions (eg. segfault) on waiting for invoked clang from the driver.

clang/lib/Driver/Driver.cpp: Don't pass through negative exit status, or parent would be confused.

llvm::sys::Program::Wait(): Suppose 0x8000XXXX and 0xC000XXXX as abnormal exit code and pass it as negative value.

Win32 Exception Handler: Exit with ExceptionCode on an unhandle exception.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145389 91177308-0d34-0410-b5e6-96231b3b80d8

12 years ago[libclang] Make the test portable.
Argyrios Kyrtzidis [Tue, 29 Nov 2011 05:48:01 +0000 (05:48 +0000)]
[libclang] Make the test portable.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145377 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoPR10101: Recover better from a common copy-paste error: if a function
Richard Smith [Tue, 29 Nov 2011 05:27:40 +0000 (05:27 +0000)]
PR10101: Recover better from a common copy-paste error: if a function
declaration at namespace scope is followed by a semicolon and an open-brace
(or in C++, a 'try', ':' or '='), then the error is probably a function
definition with a spurious ';', rather than a mysterious '{'.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145372 91177308-0d34-0410-b5e6-96231b3b80d8

12 years ago[libclang] Make clang_findReferencesInFile also work on macros (find all expansions...
Argyrios Kyrtzidis [Tue, 29 Nov 2011 03:14:11 +0000 (03:14 +0000)]
[libclang] Make clang_findReferencesInFile also work on macros (find all expansions/definition
of a macro in a file).

As a bonus, also make searching for declarations more efficient by ignoring
preprocessing entities when we know that we are looking for a declaration.

Fixes rdar://10427411.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145369 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd Clang release notes for OpenCL C support.
Peter Collingbourne [Tue, 29 Nov 2011 02:03:07 +0000 (02:03 +0000)]
Add Clang release notes for OpenCL C support.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145360 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFix URL typo.
Peter Collingbourne [Tue, 29 Nov 2011 02:03:03 +0000 (02:03 +0000)]
Fix URL typo.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145359 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoobjc: warn if NSObject attribute appears other than in a typedef.
Fariborz Jahanian [Tue, 29 Nov 2011 01:48:40 +0000 (01:48 +0000)]
objc: warn if NSObject attribute appears other than in a typedef.
// rdar://10453342

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145358 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFix serialized diagnostics to handle FixIts that only remove text. Fixes <rdar:...
Ted Kremenek [Tue, 29 Nov 2011 00:30:52 +0000 (00:30 +0000)]
Fix serialized diagnostics to handle FixIts that only remove text.  Fixes <rdar://problem/10473903>.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145339 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFix a spelling error pointed out by Sebastien, and tidy up the
Chandler Carruth [Tue, 29 Nov 2011 00:24:20 +0000 (00:24 +0000)]
Fix a spelling error pointed out by Sebastien, and tidy up the
formatting here a bit... mostly to my preferred bikeshed-blue.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145337 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRemove the last of my notes. I don't think these really need to be in
Chandler Carruth [Tue, 29 Nov 2011 00:24:18 +0000 (00:24 +0000)]
Remove the last of my notes. I don't think these really need to be in
the release notes despite their awesomeness. If we had a thorough
discussion of the performance of Clang in 2.9 vs. 3.0, the first would
be more relevant, but we don't. The serialization stuff hopefully isn't
terribly visible to end users.

Objections to these omissions are of course welcome. =]

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145336 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoLast major chunk of features. This covers a couple of language
Chandler Carruth [Tue, 29 Nov 2011 00:15:26 +0000 (00:15 +0000)]
Last major chunk of features. This covers a couple of language
extensions and one infrastructure feature addition that has a direct
impact on other projects which use Clang.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145335 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAnd sink the GNU runtime bit into this section as a stub.
Chandler Carruth [Tue, 29 Nov 2011 00:15:25 +0000 (00:15 +0000)]
And sink the GNU runtime bit into this section as a stub.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145334 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFlesh out the Objective-C section a bit. This may well need some love
Chandler Carruth [Tue, 29 Nov 2011 00:15:23 +0000 (00:15 +0000)]
Flesh out the Objective-C section a bit. This may well need some love
from the Objective-C experts, but the basic stuff is there now.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145333 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoThe _setjmp builtin library function should have the "returns twice"
Bill Wendling [Tue, 29 Nov 2011 00:10:10 +0000 (00:10 +0000)]
The _setjmp builtin library function should have the "returns twice"
attribute. This prevents the stack slot allocator from coming along and using a
stack which it thinks is available but isn't.
<rdar://problem/10492556>

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145332 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd a couple more GCC versions to C++ search paths for MinGW. Patch by Ruben Van...
Eli Friedman [Mon, 28 Nov 2011 23:58:55 +0000 (23:58 +0000)]
Add a couple more GCC versions to C++ search paths for MinGW.  Patch by Ruben Van Boxem.

(We should probably start doing some sort of autodetection like we do on Linux at some point.)

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145326 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoCFI is mentioned on the LLVM releases as the clang bits are relatively small.
Rafael Espindola [Mon, 28 Nov 2011 23:58:04 +0000 (23:58 +0000)]
CFI is mentioned on the LLVM releases as the clang bits are relatively small.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145325 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoA couple driver fixes for PPC Linux. Patches by Michael Kostylev. PR11444/PR11445.
Eli Friedman [Mon, 28 Nov 2011 23:46:52 +0000 (23:46 +0000)]
A couple driver fixes for PPC Linux.  Patches by Michael Kostylev.  PR11444/PR11445.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145321 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoUpdate release notes with 2 features now supported in -fms-extensions mode.
Francois Pichet [Mon, 28 Nov 2011 23:46:15 +0000 (23:46 +0000)]
Update release notes with 2 features now supported in -fms-extensions mode.
I think that's enough for my release notes.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145320 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRelease notes: add link to ISO C++ 2011 standard from the C++11 section.
Richard Smith [Mon, 28 Nov 2011 23:35:03 +0000 (23:35 +0000)]
Release notes: add link to ISO C++ 2011 standard from the C++11 section.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145317 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoUpdate release notes with information on MSVC mode.
Francois Pichet [Mon, 28 Nov 2011 23:30:46 +0000 (23:30 +0000)]
Update release notes with information on MSVC mode.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145315 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoCorrect the code generation for function arguments of vec3 types on x86_64 when they...
Tanya Lattner [Mon, 28 Nov 2011 23:18:11 +0000 (23:18 +0000)]
Correct the code generation for function arguments of vec3 types on x86_64 when they are greater than 128 bits. This was incorrectly coercing things like long3 into a double2.
Add test case.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145312 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRelease notes: fix up formatting of diagnostic example.
Richard Smith [Mon, 28 Nov 2011 23:16:15 +0000 (23:16 +0000)]
Release notes: fix up formatting of diagnostic example.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145311 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoWhen attempting to load a module that is not in the module cache,
Douglas Gregor [Mon, 28 Nov 2011 23:16:06 +0000 (23:16 +0000)]
When attempting to load a module that is not in the module cache,
return the module itself (in the module map) rather than returning the
umbrella header used to build the module. While doing this, make sure
that we're inferring modules for frameworks to build that module.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145310 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoExtract a Windows section in the release notes. Hopefully this is more
Chandler Carruth [Mon, 28 Nov 2011 23:11:27 +0000 (23:11 +0000)]
Extract a Windows section in the release notes. Hopefully this is more
accurate than my original notes were based on IRC conversations. Windows
folks, please edit as needed to make this closer to the truth if I've
still got it wrong.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145309 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoCreate a stub for Nick to hack on, nuking another of my rough notes.
Chandler Carruth [Mon, 28 Nov 2011 23:02:13 +0000 (23:02 +0000)]
Create a stub for Nick to hack on, nuking another of my rough notes.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145308 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoPull the uninitialized values rewrite into the diagnostics section, and
Chandler Carruth [Mon, 28 Nov 2011 22:54:33 +0000 (22:54 +0000)]
Pull the uninitialized values rewrite into the diagnostics section, and
add a bit to that section about the many bug-finding warnings that Clang
has grown since 2.9 as this is one of the more visible new additions.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145307 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRemove some features that don't really seem major enough or widely used
Chandler Carruth [Mon, 28 Nov 2011 22:54:31 +0000 (22:54 +0000)]
Remove some features that don't really seem major enough or widely used
enough to merit space in the release notes.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145306 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd a release notes section for C1X language features supported by clang 3.0.
Richard Smith [Mon, 28 Nov 2011 22:48:25 +0000 (22:48 +0000)]
Add a release notes section for C1X language features supported by clang 3.0.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145305 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoPull out the libclang section and try to clean it up some. This one
Chandler Carruth [Mon, 28 Nov 2011 22:43:32 +0000 (22:43 +0000)]
Pull out the libclang section and try to clean it up some. This one
feels a bit spartan currently.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145302 91177308-0d34-0410-b5e6-96231b3b80d8

12 years ago[libclang] Protect against the declaration's SourceRange being invalid
Argyrios Kyrtzidis [Mon, 28 Nov 2011 22:38:07 +0000 (22:38 +0000)]
[libclang] Protect against the declaration's SourceRange being invalid
before passing to RangeCompare.

Though no idea how this can occur with the decls returned from
findFileRegionDecls().

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145301 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoWe now have text (or comment stubs for others) for these...
Chandler Carruth [Mon, 28 Nov 2011 22:36:40 +0000 (22:36 +0000)]
We now have text (or comment stubs for others) for these...

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145299 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoExpand and clean up the diagnostics section.
Chandler Carruth [Mon, 28 Nov 2011 22:34:59 +0000 (22:34 +0000)]
Expand and clean up the diagnostics section.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145298 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agofix html markup
Kostya Serebryany [Mon, 28 Nov 2011 22:34:10 +0000 (22:34 +0000)]
fix html markup

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145297 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFix some possible gcc-4.2 may be used uninitialized warnings.
Daniel Dunbar [Mon, 28 Nov 2011 22:19:36 +0000 (22:19 +0000)]
Fix some possible gcc-4.2 may be used uninitialized warnings.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145293 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoCreate a more organized (but still commented out as not very useful)
Chandler Carruth [Mon, 28 Nov 2011 22:17:58 +0000 (22:17 +0000)]
Create a more organized (but still commented out as not very useful)
stub for OpenCL work. I can't really dig enough out of the commit log
messages other than to tell that a lot of work went into this in the 2.9
-> 3.0 timeframe. I'll let the folks touching it decide if it merits
a spot in the release notes and provide the appropriate details if so.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145291 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd missing equals.
Benjamin Kramer [Mon, 28 Nov 2011 22:17:09 +0000 (22:17 +0000)]
Add missing equals.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145290 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoCreate a 3.1 notes section in a comment so that the next batch are a bit
Chandler Carruth [Mon, 28 Nov 2011 22:12:44 +0000 (22:12 +0000)]
Create a 3.1 notes section in a comment so that the next batch are a bit
easier. Move the CUDA bits and the C1X/C++11 atomics stuff there. We
haven't exposed a __has_feature for the atomic builtins, so none of this
is available yet...

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145288 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoPeter says this shouldn't make it to the relnotes, it's too immature at
Chandler Carruth [Mon, 28 Nov 2011 22:06:59 +0000 (22:06 +0000)]
Peter says this shouldn't make it to the relnotes, it's too immature at
this stage.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145286 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFlesh out and pretty-up the driver section. This could probably use some
Chandler Carruth [Mon, 28 Nov 2011 21:56:30 +0000 (21:56 +0000)]
Flesh out and pretty-up the driver section. This could probably use some
more love w.r.t. platforms other than Linux?

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145285 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd a brief mention of the warning flag name updates associated with the
Chandler Carruth [Mon, 28 Nov 2011 21:55:34 +0000 (21:55 +0000)]
Add a brief mention of the warning flag name updates associated with the
C++11 standard.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145284 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoTidy up, wrap lines, and use <code> tags more consistently.
Chandler Carruth [Mon, 28 Nov 2011 21:47:51 +0000 (21:47 +0000)]
Tidy up, wrap lines, and use <code> tags more consistently.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145283 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoCleanup the Release Notes for the static analyzer:
Anna Zaks [Mon, 28 Nov 2011 21:31:55 +0000 (21:31 +0000)]
Cleanup the Release Notes for the static analyzer:

The performance improvement was committed after the 3.0 branch.
Constructors/destructors are handled by the CFG, but we do not do anything
special for them in the analyzer yet.

Since we do not have an open source release qualification for the analyzer,
we are not investing into creating the proper release notes for it.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145281 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFirst version of AddressSanitizer docs; documentation for __has_feature(address_sanit...
Kostya Serebryany [Mon, 28 Nov 2011 20:51:02 +0000 (20:51 +0000)]
First version of AddressSanitizer docs; documentation for __has_feature(address_sanitizer)

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145276 91177308-0d34-0410-b5e6-96231b3b80d8

12 years ago[analyzer] Add more simple taint tests.
Anna Zaks [Mon, 28 Nov 2011 20:43:40 +0000 (20:43 +0000)]
[analyzer] Add more simple taint tests.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145275 91177308-0d34-0410-b5e6-96231b3b80d8

12 years ago[analyzer] Minor cleanup of SValBuilder: Comments + code reuse.
Anna Zaks [Mon, 28 Nov 2011 20:43:37 +0000 (20:43 +0000)]
[analyzer] Minor cleanup of SValBuilder: Comments + code reuse.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145274 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFix comment.
Rafael Espindola [Mon, 28 Nov 2011 20:05:27 +0000 (20:05 +0000)]
Fix comment.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145271 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoWhen synthesizing an implicitly-defined copy or move constructor, or
Douglas Gregor [Mon, 28 Nov 2011 20:03:15 +0000 (20:03 +0000)]
When synthesizing an implicitly-defined copy or move constructor, or
when computing the exception specification of a copy or move constructor,
ignore non-static data member initializers. Fixes PR11418 /
<rdar://problem/10478642>.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145269 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd a release notes section on new C++11 language features, and flesh it out.
Richard Smith [Mon, 28 Nov 2011 20:02:05 +0000 (20:02 +0000)]
Add a release notes section on new C++11 language features, and flesh it out.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145268 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRemove code made redundant by my previous patch.
Fariborz Jahanian [Mon, 28 Nov 2011 19:56:36 +0000 (19:56 +0000)]
Remove code made redundant by my previous patch.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145266 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agopinpoint name/location of deprecated/unavailable enumerator
Fariborz Jahanian [Mon, 28 Nov 2011 19:45:58 +0000 (19:45 +0000)]
pinpoint name/location of deprecated/unavailable enumerator
whose enum has been made deprecated/unavailable in the warning.
// rdar://10201690

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145264 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd a proper blurb for the PPCallbacks features.
Chandler Carruth [Mon, 28 Nov 2011 19:17:25 +0000 (19:17 +0000)]
Add a proper blurb for the PPCallbacks features.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145261 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoThis doesn't really seem worthy of a relnote... Shout if you disagree!
Chandler Carruth [Mon, 28 Nov 2011 19:11:25 +0000 (19:11 +0000)]
This doesn't really seem worthy of a relnote... Shout if you disagree!

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145259 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFill in a section for the instantiation -> expansion rename. Not great,
Chandler Carruth [Mon, 28 Nov 2011 19:06:34 +0000 (19:06 +0000)]
Fill in a section for the instantiation -> expansion rename. Not great,
but better.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145258 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd proper text for the Diagnostic API changes.
Chandler Carruth [Mon, 28 Nov 2011 18:55:47 +0000 (18:55 +0000)]
Add proper text for the Diagnostic API changes.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145257 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoobjc: turn warning for property type mismatch in
Fariborz Jahanian [Mon, 28 Nov 2011 18:38:27 +0000 (18:38 +0000)]
objc: turn warning for property type mismatch in
primary and its continuation class into error.
// rdar://10142679

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145255 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd a release note for Objective-C related result types
Douglas Gregor [Mon, 28 Nov 2011 17:51:39 +0000 (17:51 +0000)]
Add a release note for Objective-C related result types

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145252 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoNote that code completion now works better for in-class member functions
Douglas Gregor [Mon, 28 Nov 2011 17:50:36 +0000 (17:50 +0000)]
Note that code completion now works better for in-class member functions

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145251 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoWhen checking a call to a builtin atomic operation, be sure to
Douglas Gregor [Mon, 28 Nov 2011 16:30:08 +0000 (16:30 +0000)]
When checking a call to a builtin atomic operation, be sure to
consider the _<width> variants as well, which we'll see if we're
performing the type checking in a template instantiation where the
call expression itself was originally not type-dependent. Fixes
PR11411.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145248 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAnd that completes my sweep through commits for things that might be
Chandler Carruth [Mon, 28 Nov 2011 13:02:29 +0000 (13:02 +0000)]
And that completes my sweep through commits for things that might be
worth noting in the release notes. These remain raw notes. I'll be
re-writing them into nice prose first thing tomorrow, with help from
others. A couple of notes for any reading the commits:

If you don't see something that should be mentioned, feel free to add
a note (or even a nicely written section) about it! I haven't really
done the static analyzer justice here as I don't really know what the
significant changes are other than mile-high stuff like watching it grow
C++ support and a more robust CFG. I also worry I've missed important
stuff in the Objective-C world.

If you see something that isn't worth mentioning, just delete it. I know
there are several things like this. I plan to prune the list down as
I flesh things out.

If you're name or email is on a bullet, I'll likely be sending you an
email asking for any input on that subject. For many of these I can fill
in something generic, and I'll just want you to give it a once-over.
However, if you have time, feel free to just write the blurb yourself
and drop it in, or drop it in an email to me.

Finally, *WOW* has a lot happened in Clang... I shouldn't have dreaded
(and put off) this so much, it was kind of awesome to go back and watch
the evolution. Anyways, these should be in a reasonable draft state
early tomorrow.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145247 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFinished with August's commits, and actually added a clearly missing
Chandler Carruth [Mon, 28 Nov 2011 12:24:23 +0000 (12:24 +0000)]
Finished with August's commits, and actually added a clearly missing
section on libclang.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145246 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoJuly's notes..
Chandler Carruth [Mon, 28 Nov 2011 12:24:21 +0000 (12:24 +0000)]
July's notes..

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145245 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRemoved useless ImplicitCast nodes in explicit cstyle and static casts
Nicola Gigante [Mon, 28 Nov 2011 12:21:57 +0000 (12:21 +0000)]
Removed useless ImplicitCast nodes in explicit cstyle and static casts

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145244 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoJuly was a bit quiet to... except for ARC. ;]
Chandler Carruth [Mon, 28 Nov 2011 11:27:33 +0000 (11:27 +0000)]
July was a bit quiet to... except for ARC. ;]

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145242 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoJune was a quiet month... I can't imagine why... ;]
Chandler Carruth [Mon, 28 Nov 2011 10:57:14 +0000 (10:57 +0000)]
June was a quiet month... I can't imagine why... ;]

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145241 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoNotes through another month... a *really* busy month, but mostly bug
Chandler Carruth [Mon, 28 Nov 2011 09:43:30 +0000 (09:43 +0000)]
Notes through another month... a *really* busy month, but mostly bug
fixing.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145237 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd the first month's commit notes.
Chandler Carruth [Mon, 28 Nov 2011 08:41:06 +0000 (08:41 +0000)]
Add the first month's commit notes.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145236 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoInstall c-index-test and clang-c/Index.h as internal files. rdar://10217046
Bob Wilson [Mon, 28 Nov 2011 08:03:54 +0000 (08:03 +0000)]
Install c-index-test and clang-c/Index.h as internal files. rdar://10217046

Specify that these files should be installed to the optional internal
install location as specified by configure's --with-internal-prefix.
If that option is not used, they'll be installed to the default prefix
as before.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145235 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoBegin sketching out the Clang release notes. The plan is to link to
Chandler Carruth [Mon, 28 Nov 2011 07:16:19 +0000 (07:16 +0000)]
Begin sketching out the Clang release notes. The plan is to link to
these more detailed notes from the primary LLVM release notes for Clang.
This gives us a nice place to flesh out in plenty of detail the major
changes that have happened in Clang land since 2.9.

I've outlined a very rough structure based on the LLVM release notes
structure and what seems like useful divisions in the Clang landscape
(e.g., language-specific stuff is relevant to a narrower audience).

I'll be first converting my brain-dump-ish notes from the commit logs,
and then cleaning here. Suggestions on structure welcome. Typo
corrections, spelling fixes (oh how I'll need them), all welcome; just
commit away.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145233 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agotest/lit.cfg: Enhance getRegisteredTargets() to retrieve +Asserts.
NAKAMURA Takumi [Mon, 28 Nov 2011 05:09:42 +0000 (05:09 +0000)]
test/lit.cfg: Enhance getRegisteredTargets() to retrieve +Asserts.

  - s/getRegisteredTargets/get_llc_props/g
  - get_llc_props() returns dict {"set_of_targets", "enable_assertions"}
  - Enable the feature "asserts".
    test/Driver/darwin-verify-debug.c had expected it.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145231 91177308-0d34-0410-b5e6-96231b3b80d8

12 years ago[libclang] Indexing API: If the client requested to get a CXTranslationUnit after
Argyrios Kyrtzidis [Mon, 28 Nov 2011 04:56:00 +0000 (04:56 +0000)]
[libclang] Indexing API: If the client requested to get a CXTranslationUnit after
indexing, honor all the TU options.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145229 91177308-0d34-0410-b5e6-96231b3b80d8

12 years ago[libclang] Indexing API: Capture diagnostics during indexing.
Argyrios Kyrtzidis [Mon, 28 Nov 2011 04:55:55 +0000 (04:55 +0000)]
[libclang] Indexing API: Capture diagnostics during indexing.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145228 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAnother silly workaround for MSVC.
Peter Collingbourne [Mon, 28 Nov 2011 04:29:10 +0000 (04:29 +0000)]
Another silly workaround for MSVC.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145227 91177308-0d34-0410-b5e6-96231b3b80d8

12 years ago[arcmt] Integrate GC __weak into property attributes even when we don't have
Argyrios Kyrtzidis [Mon, 28 Nov 2011 02:04:36 +0000 (02:04 +0000)]
[arcmt] Integrate GC __weak into property attributes even when we don't have
the implementation.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145224 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoSigh, another workaround for MSVC.
Peter Collingbourne [Mon, 28 Nov 2011 00:41:08 +0000 (00:41 +0000)]
Sigh, another workaround for MSVC.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145211 91177308-0d34-0410-b5e6-96231b3b80d8

12 years ago[arcmt] Don't add __weak if there is already a GC __weak and make sure to clear
Argyrios Kyrtzidis [Mon, 28 Nov 2011 00:23:12 +0000 (00:23 +0000)]
[arcmt] Don't add __weak if there is already a GC __weak and make sure to clear
__weak from a readonly property.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145210 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoWork around a gcc4.2 bug.
Peter Collingbourne [Mon, 28 Nov 2011 00:18:21 +0000 (00:18 +0000)]
Work around a gcc4.2 bug.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145209 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoIn Sema::MaybeBindToTemporary, create a CXXBindTemporaryExpr for an
Peter Collingbourne [Sun, 27 Nov 2011 22:09:28 +0000 (22:09 +0000)]
In Sema::MaybeBindToTemporary, create a CXXBindTemporaryExpr for an
array of objects with non-trivial destructors.  PR11365.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145203 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoWhen destroying temporaries, instead of a custom cleanup use the
Peter Collingbourne [Sun, 27 Nov 2011 22:09:22 +0000 (22:09 +0000)]
When destroying temporaries, instead of a custom cleanup use the
generic pushDestroy function.

This would reduce the number of useful declarations in
CGTemporaries.cpp to one.  Since CodeGenFunction::EmitCXXTemporary
does not deserve its own file, move it to CGCleanup.cpp and delete
CGTemporaries.cpp.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145202 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoMake our handling of MMX x SSE closer to what gcc does:
Rafael Espindola [Sun, 27 Nov 2011 20:00:43 +0000 (20:00 +0000)]
Make our handling of MMX x SSE closer to what gcc does:

* Enabling sse enables mmx.
* Disabling (-mno-mmx) mmx, doesn't disable sse (we got this right already).
* The order in not important. -msse -mno-mmx is the same as -mno-mmx -msse.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145194 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd inreg attributes to reference arguments.
Rafael Espindola [Sun, 27 Nov 2011 18:35:39 +0000 (18:35 +0000)]
Add inreg attributes to reference arguments.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145189 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoReference initialization with initializer lists.
Sebastian Redl [Sun, 27 Nov 2011 16:50:07 +0000 (16:50 +0000)]
Reference initialization with initializer lists.

This supports single-element initializer lists for references according to DR1288, as well as creating temporaries and binding to them for other initializer lists.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145186 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoError on non x86 architectures.
Rafael Espindola [Sun, 27 Nov 2011 15:21:33 +0000 (15:21 +0000)]
Error on non x86 architectures.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145185 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFix file name in comments.
Rafael Espindola [Sun, 27 Nov 2011 15:13:54 +0000 (15:13 +0000)]
Fix file name in comments.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145184 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoUse libcxx makefile's do-installhdrs target. <rdar://problem/10397739>
Bob Wilson [Sun, 27 Nov 2011 06:13:25 +0000 (06:13 +0000)]
Use libcxx makefile's do-installhdrs target.  <rdar://problem/10397739>

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145168 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd the minimum implementation of cpuid.h. This works on "modern" intel cpus
Rafael Espindola [Sat, 26 Nov 2011 20:53:19 +0000 (20:53 +0000)]
Add the minimum implementation of cpuid.h. This works on "modern" intel cpus
and on clang, which seams to handled "=b" correctly even when ebx is the
PIC register.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145149 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoTest commit
Nicola Gigante [Sat, 26 Nov 2011 16:20:01 +0000 (16:20 +0000)]
Test commit

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145147 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFixed lexical declaration context when instantiating a friend / out-of-line class...
Abramo Bagnara [Sat, 26 Nov 2011 13:33:46 +0000 (13:33 +0000)]
Fixed lexical declaration context when instantiating a friend / out-of-line class template member.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145146 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoSet __OPTIMIZE_SIZE__ on -Os and -Oz. This matches gcc's behaviour on both OS X
Rafael Espindola [Sat, 26 Nov 2011 06:21:20 +0000 (06:21 +0000)]
Set __OPTIMIZE_SIZE__ on -Os and -Oz. This matches gcc's behaviour on both OS X
and linux.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145142 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoIn Microsoft mode, make "Unqualified lookup into dependent bases of class templates...
Francois Pichet [Fri, 25 Nov 2011 01:10:54 +0000 (01:10 +0000)]
In Microsoft mode, make "Unqualified lookup into dependent bases of class templates" works  inside a friend function definition at class scope.

Basically we have to look into the parent *lexical* DeclContext for friend functions at class scope. That's because calling GetParent() return the namespace or file DeclContext.

This fixes all remaining cases of "Unqualified lookup into dependent bases of class templates" when parsing MFC code with clang.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145127 91177308-0d34-0410-b5e6-96231b3b80d8