https://bugs.llvm.org/show_bug.cgi?id=48850
Bug ID: 48850
Summary: Wrong size of union with zero-sized fields
Product: clang
Version: 11.0
Hardware: PC
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: C
Assignee: unassignedclangb...@nondot.org
Reporter: ju.o...@gmail.com
CC: blitzrak...@gmail.com, dgre...@apple.com,
erik.pilking...@gmail.com, llvm-bugs@lists.llvm.org,
richard-l...@metafoo.co.uk
Consider
union X {
long long c[0];
};
int f(void) {
return sizeof(union X);
}
msvc returns 8, clang returns 4 for the x86_64-pc-windows-msvc target.
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs