test/Driver: Check that @ arguments that aren't files are handled

This tests the bug fix in llvm r196620.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196621 91177308-0d34-0410-b5e6-96231b3b80d8
Fixing assertion failure introduced in 196602.

Also includes a minor refactor with no functional change.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196627 91177308-0d34-0410-b5e6-96231b3b80d8
ObjectiveC. Continuing implementation of objc_bridge_related
attribute in sema and issuing a variety of diagnostics lazily 
for misuse of this attribute (and what to do) when converting 
from CF types to ObjectiveC types (and vice versa).
// rdar://15499111


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196629 91177308-0d34-0410-b5e6-96231b3b80d8
Pass correct flags to assembler and linker for OpenBSD on AMD64, PowerPC
and MIPS64. From Brad Smith.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196630 91177308-0d34-0410-b5e6-96231b3b80d8
Give a more appropriate diagnostic when a template specialization or
instantiation appears in a non-enclosing namespace (the previous diagnostic
talked about the C++98 rule even in C++11 mode).


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196642 91177308-0d34-0410-b5e6-96231b3b80d8
Add a SubsetSubject in Attr.td to automate checking of where the objc_designated_initializer
attribute is acceptable.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196644 91177308-0d34-0410-b5e6-96231b3b80d8
Type traits: No need for switch to handle __builtin_types_compatible_p

__builtin_types_compatible_p() isn't a C++ type trait at all, rather a GNU C
special-case, so it's fine to use BoolTy the default return type for binary
type traits.

This brings BTT in line with other arities that already default to BoolTy.

Cleanup only, no change in behaviour.

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

There was already a condition earlier in the function so just place the check
there.

Cleanup only.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196647 91177308-0d34-0410-b5e6-96231b3b80d8
Changed ConditionValue argument to PPCallbacks If and Elif callbacks to be a 3-state enum.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196648 91177308-0d34-0410-b5e6-96231b3b80d8
CommentLexer: eliminate an NDEBUG from the headers

Code in headers shouldn't be conditional on the build configuration.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196656 91177308-0d34-0410-b5e6-96231b3b80d8
Eliminate the last trivial NDEBUG uses in clang headers

assert(sanity()) reads so much better than preprocessor conditional blocks.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196657 91177308-0d34-0410-b5e6-96231b3b80d8
CodeGen: Don't emit linkage on thunks that aren't emitted because they're vararg.

This can happen when we're trying to emit a thunk with available_externally
linkage with optimization enabled but bail because it doesn't make sense
for vararg functions.

PR18098.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196658 91177308-0d34-0410-b5e6-96231b3b80d8
[REFACTOR] Refactored some of the generic-lambda capturing code.

Employed the following refactorings:
  - Renamed some functions
  - Introduced explaining variables
  - Cleaned up & added comments
  - Used Optional<unsigned> for return value instead of an out parameter
  - Added assertions
  - Constified a few member functions
  
No functionality change.
All regressions pass.  



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196662 91177308-0d34-0410-b5e6-96231b3b80d8
Delete the now unnecessary test/generic-lambda-unimplemented-1y.cpp



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

Clang outputs LLVM one top level decl at a time. This combined with the
visibility computation code looking for the newest NamespaceDecl would cause
it to produce different results for nested namespaces.

The two options for producing consistent results are
* Delay codegen of anything inside a namespace until the end of the file.
* Don't look for the newest NamespaceDecl.

This patch implements the second option.
This matches the gcc behavior too.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196712 91177308-0d34-0410-b5e6-96231b3b80d8
Extend assembler handling for NetBSD/MIPS to pass down the correct ABI,
architecture and PIC flag.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196720 91177308-0d34-0410-b5e6-96231b3b80d8
Fix an assertion introduced by my previous refactoring.

Add back the test that was triggering the assertion (which I removed mistakenly thinking it was triggering just a warning and not an assertion).  My error was brought to my attention by Rafael (Thanks!).



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196721 91177308-0d34-0410-b5e6-96231b3b80d8
Fix the message to go along with the assertion that was just fixed.

argh!




git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196722 91177308-0d34-0410-b5e6-96231b3b80d8
Move a generic lambda test into the more logical test file.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@196723 91177308-0d34-0410-b5e6-96231b3b80d8
ARM: teach Sema that "r" can match 64-bit values

We already support using "r" on 64-bit values (a GPRPair is
allocated), but Sema doesn't know this yet so issues a warning. This
should fix it.

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