]> granicus.if.org Git - clang/commitdiff
Don't error on C++ linkage; if we don't support that, there are
authorEli Friedman <eli.friedman@gmail.com>
Sat, 1 Aug 2009 20:48:04 +0000 (20:48 +0000)
committerEli Friedman <eli.friedman@gmail.com>
Sat, 1 Aug 2009 20:48:04 +0000 (20:48 +0000)
serious issues :)

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

lib/CodeGen/CodeGenModule.cpp

index a5b0dacd762b5ab6af894dfd93e4f5e7a4b1ca04..ec9a97aabd6618f3c2f60899d8591c1a7201ace4 100644 (file)
@@ -1493,7 +1493,8 @@ void CodeGenModule::EmitNamespace(const NamespaceDecl *ND) {
 
 // EmitLinkageSpec - Emit all declarations in a linkage spec.
 void CodeGenModule::EmitLinkageSpec(const LinkageSpecDecl *LSD) {
-  if (LSD->getLanguage() != LinkageSpecDecl::lang_c) {
+  if (LSD->getLanguage() != LinkageSpecDecl::lang_c &&
+      LSD->getLanguage() != LinkageSpecDecl::lang_cxx) {
     ErrorUnsupported(LSD, "linkage spec");
     return;
   }