Objective-C. Redo turning off designated initialization warnings on
'init' methods which are unavailable. Subclasses of NSObject
have to implement such methods as a common pattern to prevent
user's own implementation. // rdar://16305460


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@203984 91177308-0d34-0410-b5e6-96231b3b80d8
Implement the MS extension __identifier properly: take a token and strip it of
its keywordliness.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@203987 91177308-0d34-0410-b5e6-96231b3b80d8
ASTTests//EvaluateAsRValueTest.cpp: Appease *-win32 target to add -fno-delayed-template-parsing.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@203991 91177308-0d34-0410-b5e6-96231b3b80d8
Start breaking -Wunreachable-code up into different diagnostic groups.

Recent work on -Wunreachable-code has focused on suppressing uninteresting
unreachable code that center around "configuration values", but
there are still some set of cases that are sometimes interesting
or uninteresting depending on the codebase.  For example, a dead
"break" statement may not be interesting for a particular codebase,
potentially because it is auto-generated or simply because code
is written defensively.

To address these workflow differences, -Wunreachable-code is now
broken into several diagnostic groups:

-Wunreachable-code: intended to be a reasonable "default" for
most users.

and then other groups that turn on more aggressive checking:

-Wunreachable-code-break: warn about dead break statements

-Wunreachable-code-trivial-return: warn about dead return statements
that return "trivial" values (e.g., return 0).  Other return
statements that return non-trivial values are still reported
under -Wunreachable-code (this is an area subject to more refinement).

-Wunreachable-code-aggressive: supergroup that enables all these
groups.

The goal is to eventually make -Wunreachable-code good enough to
either be in -Wall or on-by-default, thus finessing these warnings
into different groups helps achieve maximum signal for more users.

TODO: the tests need to be updated to reflect this extra control
via diagnostic flags.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@203994 91177308-0d34-0410-b5e6-96231b3b80d8
[C++11] Add 'override' keyword to virtual methods that override their base class.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@203999 91177308-0d34-0410-b5e6-96231b3b80d8
Further refine -Wunreachable-code groups so that -Wno-unreachable-code-break doesn't turn off all unreachable code warnings.

Also relax unreachable 'break' and 'return' to not check for being
preceded by a call to 'noreturn'.  That turns out to not be so
interesting in practice.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@204000 91177308-0d34-0410-b5e6-96231b3b80d8
-Wunreachable-code: treat 'const bool' locals as control values.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@204001 91177308-0d34-0410-b5e6-96231b3b80d8
[C++11] Add 'override' keyword to virtual methods that override their base class.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@204002 91177308-0d34-0410-b5e6-96231b3b80d8
Remove dead functions from unreachable code analysis.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@204004 91177308-0d34-0410-b5e6-96231b3b80d8
Fix PR18806: Canonicalize the replacement type when deserializing a SubstTemplateTypeParmType

What's going on in the test case (without the patch applied) is this:

When the header is parsed, decltype(B()) is canonicalized to decltype(Y()),
because that was the first parsed equivalent decltype expression. Hence, the
TemplateSpecializationType for Id<decltype(B())> ends up with
SubstTemplateTypeParmType(T, decltype(Y())) as the AliasedType member.

When the PCH file is included and the AST reader reads Id<decltype(B())>, it
sees decltype(B()) before decltype(Y()). So, this time decltype(B()) ends up
being the canonical type for both decltypes, which leads to an assert violation
when the reader calls getSubstTemplateTypeParmType with the non-canonical
decltype(Y()) as the replacement type.

Reviewers: rsmith

Reviewed By: rsmith

CC: cfe-commits, aemerson

Differential Revision: http://llvm-reviews.chandlerc.com/D3073

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@204005 91177308-0d34-0410-b5e6-96231b3b80d8
Serialization: Directly compare objects instead of using a functor duplicating the compare operators.

No functionality change.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@204006 91177308-0d34-0410-b5e6-96231b3b80d8
Preprocessor: Clarify the ownership of the IncludeMacroStack with unique_ptr.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@204007 91177308-0d34-0410-b5e6-96231b3b80d8
The year is 2014. MSVC is still unable to synthesize move ctors.

Work around with a ton of boilerplate.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@204009 91177308-0d34-0410-b5e6-96231b3b80d8
Make some assertions on constant expressions static.

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