summaryrefslogtreecommitdiff
path: root/test/CodeGen/const-init.c
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2012-12-02 13:20:44 +0000
committerDimitry Andric <dim@FreeBSD.org>2012-12-02 13:20:44 +0000
commit13cc256e404620c1de0cbcc4e43ce1e2dbbc4898 (patch)
tree2732d02d7d51218d6eed98ac7fcfc5b8794896b5 /test/CodeGen/const-init.c
parent657bc3d9848e3be92029b2416031340988cd0111 (diff)
Notes
Diffstat (limited to 'test/CodeGen/const-init.c')
-rw-r--r--test/CodeGen/const-init.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/test/CodeGen/const-init.c b/test/CodeGen/const-init.c
index 4f3f7ab55330..5f729b8df428 100644
--- a/test/CodeGen/const-init.c
+++ b/test/CodeGen/const-init.c
@@ -144,3 +144,18 @@ void g28() {
static v12i16 b = (v2f80){1,2};
static v2f80 c = (v12i16){0,0,0,-32768,16383,0,0,0,0,-32768,16384,0};
}
+
+// PR13643
+void g29() {
+ typedef char DCC_PASSWD[2];
+ typedef struct
+ {
+ DCC_PASSWD passwd;
+ } DCC_SRVR_NM;
+ // CHECK: @g29.a = internal global %struct.DCC_SRVR_NM { [2 x i8] c"@\00" }, align 1
+ // CHECK: @g29.b = internal global [1 x i32] [i32 ptrtoint ([5 x i8]* @.str to i32)], align 4
+ // CHECK: @g29.c = internal global [1 x i32] [i32 97], align 4
+ static DCC_SRVR_NM a = { {"@"} };
+ static int b[1] = { "asdf" };
+ static int c[1] = { L"a" };
+}