aboutsummaryrefslogtreecommitdiff
path: root/test/CodeGen/inline.c
diff options
context:
space:
mode:
authorNick Lewycky <nicholas@mxc.ca>2011-07-07 20:25:10 +0000
committerNick Lewycky <nicholas@mxc.ca>2011-07-07 20:25:10 +0000
commit2357aeec0da2740838963880edd97e43f14cb6fd (patch)
treeb54cd95afed8b1fef6506a3b7ab8d7c75a6a608b /test/CodeGen/inline.c
parentc5f90c2250f20037e604e849044442d70573507e (diff)
A redeclaration of an inline method in C99 mode should trigger emission of that
function. Fixes PR10233! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@134634 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/inline.c')
-rw-r--r--test/CodeGen/inline.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/CodeGen/inline.c b/test/CodeGen/inline.c
index 96f9c5c9d4..cbc428cc22 100644
--- a/test/CodeGen/inline.c
+++ b/test/CodeGen/inline.c
@@ -12,6 +12,7 @@
// RUN: grep "define void @test3()" %t
// RUN: grep "define available_externally i32 @test4" %t
// RUN: grep "define available_externally i32 @test5" %t
+// RUN: grep "define i32 @test6" %t
// RUN: echo "\nC99 tests:"
// RUN: %clang %s -O1 -emit-llvm -S -o %t -std=c99
@@ -27,6 +28,7 @@
// RUN: grep "define void @test3" %t
// RUN: grep "define available_externally i32 @test4" %t
// RUN: grep "define available_externally i32 @test5" %t
+// RUN: grep "define i32 @test6" %t
// RUN: echo "\nC++ tests:"
// RUN: %clang -x c++ %s -O1 -emit-llvm -S -o %t -std=c++98
@@ -84,3 +86,8 @@ extern __inline int __attribute__ ((__gnu_inline__)) test5(void)
}
void test_test5() { test5(); }
+
+// PR10233
+
+__inline int test6() { return 0; }
+extern int test6();