diff options
Diffstat (limited to 'clang/test/CodeGen/2007-09-05-ConstCtor.c')
-rw-r--r-- | clang/test/CodeGen/2007-09-05-ConstCtor.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/clang/test/CodeGen/2007-09-05-ConstCtor.c b/clang/test/CodeGen/2007-09-05-ConstCtor.c new file mode 100644 index 0000000..138b818 --- /dev/null +++ b/clang/test/CodeGen/2007-09-05-ConstCtor.c @@ -0,0 +1,14 @@ +// RUN: %clang_cc1 -Os -emit-llvm %s -o /dev/null +// PR1641 + +struct A { + unsigned long l; +}; + +void bar(struct A *a); + +void bork() { + const unsigned long vcgt = 1234; + struct A a = { vcgt }; + bar(&a); +} |