[cfe-commits] r172316 - in /cfe/trunk: lib/AST/Decl.cpp test/SemaCXX/builtins.cpp
Rafael Espindola
rafael.espindola at gmail.com
Sat Jan 12 07:27:43 PST 2013
Author: rafael
Date: Sat Jan 12 09:27:43 2013
New Revision: 172316
URL: http://llvm.org/viewvc/llvm-project?rev=172316&view=rev
Log:
bar
Modified:
cfe/trunk/lib/AST/Decl.cpp
cfe/trunk/test/SemaCXX/builtins.cpp
Modified: cfe/trunk/lib/AST/Decl.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/AST/Decl.cpp?rev=172316&r1=172315&r2=172316&view=diff
==============================================================================
--- cfe/trunk/lib/AST/Decl.cpp (original)
+++ cfe/trunk/lib/AST/Decl.cpp Sat Jan 12 09:27:43 2013
@@ -1761,6 +1761,9 @@
}
bool FunctionDecl::hasCLanguageLinkage() const {
+ if (getBuiltinID())
+ return true;
+
return hasCLanguageLinkageTemplate(*this);
}
Modified: cfe/trunk/test/SemaCXX/builtins.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/SemaCXX/builtins.cpp?rev=172316&r1=172315&r2=172316&view=diff
==============================================================================
--- cfe/trunk/test/SemaCXX/builtins.cpp (original)
+++ cfe/trunk/test/SemaCXX/builtins.cpp Sat Jan 12 09:27:43 2013
@@ -20,3 +20,7 @@
void f2() {
__builtin_isnan; // expected-error {{builtin functions must be directly called}}
}
+
+// pr14895
+typedef __typeof(sizeof(int)) size_t;
+extern "C" void *__builtin_alloca (size_t);
More information about the cfe-commits
mailing list