Sema: Inherit the flexible array property from struct fields

A record which contains a flexible array member is itself a flexible
array member.  A struct which contains such a record should also
consider itself to be a flexible array member.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@218378 91177308-0d34-0410-b5e6-96231b3b80d8
Clean up ClangTool's argument adjuster handling a bit with unique_ptr.

Make the dtor non-virtual while there. No functionality change.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@218379 91177308-0d34-0410-b5e6-96231b3b80d8
Patch to allow mangling of microsoft’s __uuidof expression for the Itanium ABI 
when under -fms-extensions. Reviewed by John McCall.
//rdar://17784718


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@218384 91177308-0d34-0410-b5e6-96231b3b80d8
Constify a functor's function call operator because it can/should be.

Patch by Graham Lee (graham@iamleeg.com)!

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@218385 91177308-0d34-0410-b5e6-96231b3b80d8
Include debug info for types referenced only via explicit cast expressions.

Most of the debug info emission is powered essentially from function
definitions - if we emit the definition of a function, we emit the types
of its parameters, the members of those types, and so on and so forth.

For types that aren't referenced even indirectly due to this - because
they only appear in temporary expressions, not in any named variable, we
need to explicitly emit/add them as is done here. This is not the only
case of such code, and we might want to consider handling "void
func(void*); ... func(new T());" (currently debug info for T is not
emitted) at some point, though GCC doesn't. There's a much broader
solution to these issues, but it's a lot of work for possibly marginal
gain (but might help us improve the default -fno-standalone-debug
behavior to be even more aggressive in some places). See the original
review thread for more details.

Patch by jyoti allur (jyoti.yalamanchili@gmail.com)!

Differential Revision: http://reviews.llvm.org/D2498

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@218390 91177308-0d34-0410-b5e6-96231b3b80d8
clang-format: Don't let -style=Chromium imply c++03 template formatting.

Chromium's now using some c++11 language features, so it's now fine that
clang-format produces vector<vector<int>>.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@218392 91177308-0d34-0410-b5e6-96231b3b80d8
Downgrade error about stdcall decls with no prototype to a warning

Fixes PR21027.  The MIDL compiler produces code that does this.

If we wanted to improve the warning, I think we could do this:
  void __stdcall f(); // Don't warn without -Wstrict-prototypes.
  void g() {
    f(); // Might warn, the user probably meant for f to take no args.
    f(1, 2, 3); // Warn, we have no idea what args f takes.
    f(1); // Error, this is insane, one of these calls is broken.
  }

Reviewers: thakis

Differential Revision: http://reviews.llvm.org/D5481

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

This reverts bits of r218166 that are no longer necessary now that r218394 made
-Wmissing-prototype-for-cc a regular warning.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@218400 91177308-0d34-0410-b5e6-96231b3b80d8
pass environment when invoking llvm-config and clang from lit.cfg

Use the same environment when invoking llvm-config from lit.cfg as
will be used when running tests, so that ASAN_OPTIONS, INCLUDE, etc.
are present.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@218404 91177308-0d34-0410-b5e6-96231b3b80d8
Thread Safety Analysis:  Update to documentation.

The attribute documentation now conforms to Aaron Ballman's renaming of the
thread safety attributes, as well as the new paper that is due to be published
in the conference on Source Code Analysis and Manipulation (SCAM 2014) later
this week.  In addition, recent changes to the analysis, such as checking
of references and negative capabilities, are now documented.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@218420 91177308-0d34-0410-b5e6-96231b3b80d8
Fix handling of preincrement on bit-fields. This gives a bit-field in C++, but
we were failing to find that bit-field when performing integer promotions. This
brings us closer to following the standard, and closer to GCC.

In C, this change is technically a regression: we get bit-field promotions
completely wrong in C, promoting cases that are categorically not bit-field
designators. This change makes us do so slightly more consistently, though.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@218428 91177308-0d34-0410-b5e6-96231b3b80d8
Add increment/decrement operators and compound assignment operators to the
uninitialized checkers that did not have them before.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@218435 91177308-0d34-0410-b5e6-96231b3b80d8
Merge branch 'master', remote-tracking branch 'trunk/master'