Changes in directory llvm/test/CFrontend:
2007-05-29-UnionCopy.c added (r1.1) --- Log message: new testcase for PR1421: http://llvm.org/PR1421 --- Diffs of the changes: (+18 -0) 2007-05-29-UnionCopy.c | 18 ++++++++++++++++++ 1 files changed, 18 insertions(+) Index: llvm/test/CFrontend/2007-05-29-UnionCopy.c diff -c /dev/null llvm/test/CFrontend/2007-05-29-UnionCopy.c:1.1 *** /dev/null Wed May 30 00:37:28 2007 --- llvm/test/CFrontend/2007-05-29-UnionCopy.c Wed May 30 00:37:18 2007 *************** *** 0 **** --- 1,18 ---- + // RUN: %llvmgcc -S -o - -emit-llvm %s | grep memcpy + // PR1421 + + struct A { + char c; + int i; + }; + + struct B { + int c; + unsigned char x; + }; + + union U { struct A a; struct B b; }; + + void check(union U *u, union U *v) { + *u = *v; + } _______________________________________________ llvm-commits mailing list llvm-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits