mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-11-02 07:11:49 +00:00
New testcase identified by Brian Gaeke. Gotta love GCC extensions. :(
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6310 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
ddaf500c26
commit
28345b9193
20
test/C++Frontend/2003-05-23-TransparentUnion.c
Normal file
20
test/C++Frontend/2003-05-23-TransparentUnion.c
Normal file
@ -0,0 +1,20 @@
|
||||
#include <stdio.h>
|
||||
|
||||
typedef union {
|
||||
float *__fptr;
|
||||
int *__iptr;
|
||||
} UNION __attribute__ ((__transparent_union__));
|
||||
|
||||
int try(UNION U) {
|
||||
return 1;
|
||||
}
|
||||
int test() {
|
||||
int I;
|
||||
float F;
|
||||
return try(&I) | try(&F);
|
||||
}
|
||||
|
||||
int main() {
|
||||
if (test()) printf("ok");
|
||||
return 0;
|
||||
}
|
Loading…
Reference in New Issue
Block a user