fix xcore-opts.c test

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190526 91177308-0d34-0410-b5e6-96231b3b80d8
Teach RAV to visit parameter variable declarations of implicit functions. Fixes PR16182.

Normally RAV visits parameter variable declarations of a function by traversing the TypeLoc of
the parameter declarations. However, for implicit functions, their parameters don't have any
TypeLoc, because they are implicit.

So for implicit functions, we visit their parameter variable declarations by traversing them through
the function declaration, and visit them accordingly.

Reviewed by Richard Smith and Manuel Klimek.




git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190528 91177308-0d34-0410-b5e6-96231b3b80d8
clang-cl: Warn about overriding /MD with /MT etc.

This also bakes the /M options into a separate option group to make
them easier to refer to from the code.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190529 91177308-0d34-0410-b5e6-96231b3b80d8
[analyzer] Handle zeroing constructors for fields of structs with empty bases.

RegionStore tries to protect against accidentally initializing the same
region twice, but it doesn't take subregions into account very well. If
the outer region being initialized is a struct with an empty base class,
the offset of the first field in the struct will be 0. When we initialize
the base class, we may invalidate the contents of the struct by providing
a default value of Unknown (or some new symbol). We then go to initialize
the member with a zeroing constructor, only to find that the region at
that offset in the struct already has a value. The best we can do here is
to invalidate that value and continue; neither the old default value nor
the new 0 is correct for the entire struct after the member constructor call.

The correct solution for this is to track region extents in the store.

<rdar://problem/14914316>

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


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190531 91177308-0d34-0410-b5e6-96231b3b80d8
ObjectiveC migrator. methods which look like a getter and
start with "get" are inferreed as a readonly properties.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190532 91177308-0d34-0410-b5e6-96231b3b80d8
Clarify the status of PowerPC support.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190533 91177308-0d34-0410-b5e6-96231b3b80d8
Test for correct usage of columnWidth in clang fixit hints.

Summary:
This test only works on systems capable of outputting UTF-8 encoded
text on the standard output (tested on linux and OS X, should XFAIL on windows,
if I haven't messed up the XFAIL line).

Reviewers: jordan_rose

Reviewed By: jordan_rose

CC: cfe-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190537 91177308-0d34-0410-b5e6-96231b3b80d8
ObjectiveC migrator. Modify inferred property name
such that it does not lower case the staring property
name if getter name (after "get" prefix) starts with 
two upper case letters.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190539 91177308-0d34-0410-b5e6-96231b3b80d8
Tablegen now generates a StringSwitch for attributes containing enumeration arguments to map strings to the proper enumeration value.  This makes error checking more consistent and reduces the amount of hand-written code required.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190545 91177308-0d34-0410-b5e6-96231b3b80d8
clang-format: Fix bug in pointer detection

Before:
  for (int i = 0; i* 2 < z; i *= 2) {}
After:
  for (int i = 0; i * 2 < z; i *= 2) {}

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190546 91177308-0d34-0410-b5e6-96231b3b80d8
ObjectiveC migration. NS_RETURNS_NOT_RETAINED is the default for
unknown methods which return Cocoa objects. No need to annotate
such methods.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190555 91177308-0d34-0410-b5e6-96231b3b80d8
[CMake] Always include the Clang repo version, just like the autoconf build.

Now that LLVM's helper script GetSVN.cmake actually works consistently,
there's no reason not to use it. This does mean that the clangBasic target
is potentially always dirty, because CMake-generated projects do not
necessarily recalculate dependencies after running each target.

This should end the issues of the AST format changing and breaking old
module files; CMake-Clang should now detect that the version changed just
like Autoconf-Clang has.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190557 91177308-0d34-0410-b5e6-96231b3b80d8
clang/test/FixIt/fixit-unicode-with-utf8-output.c: Remove XFAIL.

It'd be another issue that the terminal and stdout(including redirects) with utf8. This test XPASSed on Win32, at least on Lit.

FYI, we don't use a triplet like "-win64" anywhere.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190559 91177308-0d34-0410-b5e6-96231b3b80d8
[CMake] Fix repository version checking dependencies harder.

Just always regenerate SVNVersion.inc. Don't worry about it not changing.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190560 91177308-0d34-0410-b5e6-96231b3b80d8
Fix the end-location of a CXXTemporaryObjectExpr when it is created with a initializer_list.

rdar://14887351

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190561 91177308-0d34-0410-b5e6-96231b3b80d8
[libclang] In clang_getLocation, check that the provided line/column is valid.

rdar://14971432

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190568 91177308-0d34-0410-b5e6-96231b3b80d8
Fix the MCTargetAsmParser API change.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190601 91177308-0d34-0410-b5e6-96231b3b80d8
[CMake] Put controversial always-recheck-revision-number behind an option.

CMake does not have the ability to perform actions before calculating
dependencies, so it can't know whether it needs to rebuild clangBasic
to update for a new revision number. CLANG_ALWAYS_CHECK_VC_REV (off by
default) will cause clangBasic to always be dirty by deleting the
generated SVNVersion.inc after use; otherwise, SVNVersion.inc will
always be updated, but only included in the final binary when clangBasic
is rebuilt.

It'd be great to find a better way to do this, but hopefully this is
still an improvement over the complete lack of version information before.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190613 91177308-0d34-0410-b5e6-96231b3b80d8
Move Compilation::PrintJob and PrintDiagnosticJob into Job::Print.

This moves the code to Job.cpp, which seems like a more natural fit,
and replaces the "is this a JobList? is this a Command?" logic with
a virtual function call.

It also removes the code duplication between PrintJob and
PrintDiagnosticJob and simplifies the code a little.

There's no functionality change here, except that the Executable is
now always printed within quotes, whereas it would previously not be
quoted in crash reports, which I think was a bug.

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

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