First version of matchers for Types and TypeLocs.

Review: http://llvm-reviews.chandlerc.com/D47

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166094 91177308-0d34-0410-b5e6-96231b3b80d8
Remove an unneeded flag from the bitrig driver tests.

Based loosely on a patch from David Hill.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166096 91177308-0d34-0410-b5e6-96231b3b80d8
Fix tests, which accidentally matched implicit code on specific
platforms to make buildbots happy.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166100 91177308-0d34-0410-b5e6-96231b3b80d8
Revert r158009 since there are some uses of artificial functions in
debug info.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166109 91177308-0d34-0410-b5e6-96231b3b80d8
Move -Wint-to-pointer-cast from -Wall to -Wmost to group it with more things.

Addressing feedback on r166039 given by Matt Beaumont-Gay.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166118 91177308-0d34-0410-b5e6-96231b3b80d8
[analyzer] Create a temporary region when accessing a struct rvalue.

In C++, rvalues that need to have their address taken (for example, to be
passed to a function by const reference) will be wrapped in a
MaterializeTemporaryExpr, which lets CodeGen know to create a temporary
region to store this value. However, MaterializeTemporaryExprs are /not/
created when a method is called on an rvalue struct, even though the 'this'
pointer needs a valid value. CodeGen works around this by creating a
temporary region anyway; now, so does the analyzer.

The analyzer also does this when accessing a field of a struct rvalue.
This is a little unfortunate, since the rest of the struct will soon be
thrown away, but it does make things consistent with the rest of the
analyzer.

This allows us to bring back the assumption that all known 'this' values
are Locs. This is a revised version of r164828-9, reverted in r164876-7.

<rdar://problem/12137950>

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166120 91177308-0d34-0410-b5e6-96231b3b80d8
[analyzer] When binding to a ParenExpr, bind to its inner expression instead.

This actually looks through several kinds of expression, such as
OpaqueValueExpr and ExprWithCleanups. The idea is that binding and lookup
should be consistent, and so if the environment needs to be modified later,
the code doing the modification will not have to manually look through these
"transparent" expressions to find the real binding to change.

This is necessary for proper updating of struct rvalues as described in
the previous commit.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166121 91177308-0d34-0410-b5e6-96231b3b80d8
[analyzer] CmpRuns: cleanup APIs, allow processing of plists with no
clang_version, fix the compare routine.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166129 91177308-0d34-0410-b5e6-96231b3b80d8
[Doc parsing]: This patch adds <Declaration> tag to 
XML comment for declarations which pretty-prints
declaration. I had to XFAIL one test annotate-comments.cpp.
This test is currently unmaintainable as written.
Dmitri G., can you see what we can do about this test.
We should change this test such that adding a new tag does not wreck
havoc to the test.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166130 91177308-0d34-0410-b5e6-96231b3b80d8
Add -std=c++1y argument, for *highly* experimental C++14 support.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166139 91177308-0d34-0410-b5e6-96231b3b80d8
Adds couple of missing warning flags so warnings can be turned
off. // rdar://12501960


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166150 91177308-0d34-0410-b5e6-96231b3b80d8
XFAIL these tests until I can figure out what is going on on
other platforms.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166151 91177308-0d34-0410-b5e6-96231b3b80d8
DR1528: C++11 doesn't allow repeated cv-qualifiers in declarators after all.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166152 91177308-0d34-0410-b5e6-96231b3b80d8
Fix -Woverloaded-virtual when the using statement refers to a base declaration of a virtual function.

GCC and Clang both do not warn on:

  struct a { virtual void func(); };
  struct b: a { virtual void func(); void func(int); };
  struct c: b { void func(int); using b::func; };

but if the "using" was using a::func GCC would still remain silent where Clang
would warn. This change makes Clang consistent with GCC's existing behavior.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166154 91177308-0d34-0410-b5e6-96231b3b80d8
DR1535: only potentially-evaluated typeid expressions are disallowed in constant
expressions, not *any* typeid on a polymorphic class type.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166156 91177308-0d34-0410-b5e6-96231b3b80d8
Update comment to match DR1502.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166158 91177308-0d34-0410-b5e6-96231b3b80d8
[libclang] Add a test for annotation of module headers

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166160 91177308-0d34-0410-b5e6-96231b3b80d8
[libclang] Invoke a ppIncludedFile callback when indexing implicit module imports.

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


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166162 91177308-0d34-0410-b5e6-96231b3b80d8
libclang/CXComment.cpp: Fix abuse of StringRef.

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