Add a note that points to the linkage specifier for the C++ linkage errors
authorAlex Lorenz <arphaman@gmail.com>
Wed, 2 Nov 2016 15:46:34 +0000 (15:46 +0000)
committerAlex Lorenz <arphaman@gmail.com>
Wed, 2 Nov 2016 15:46:34 +0000 (15:46 +0000)
commit560ae565e9fa981ce2a49282b71c1e716ff347d1
treee84aeceba2a821f6f863609ac9dd5307da27cb57
parent93f2f7fb6c323083ec39abc0b67a9b51dc416684
Add a note that points to the linkage specifier for the C++ linkage errors

This commit improves the "must have C++ linkage" error diagnostics that are
emitted for C++ declarations like templates and literal operators by adding an
additional note that points to the appropriate extern "C" linkage specifier.

rdar://19021120

Differential Revision: https://reviews.llvm.org/D26189

llvm-svn: 285823
clang/include/clang/AST/DeclBase.h
clang/include/clang/Basic/DiagnosticSemaKinds.td
clang/lib/AST/DeclBase.cpp
clang/lib/Sema/SemaDecl.cpp
clang/lib/Sema/SemaDeclCXX.cpp
clang/lib/Sema/SemaTemplate.cpp
clang/test/CXX/over/over.oper/over.literal/p6.cpp
clang/test/SemaCXX/cxx0x-defaulted-functions.cpp
clang/test/SemaTemplate/class-template-decl.cpp