http://bugzilla.gdcproject.org/show_bug.cgi?id=236
Bug ID: 236 Summary: Empty structs not copied correctly Product: GDC Version: development Hardware: ARM OS: All Status: NEW Severity: minor Priority: Normal Component: gdc Assignee: ibuc...@gdcproject.org Reporter: johannesp...@gmail.com There's a failing unittest on ARM in rt.aaA. The test uses a struct without any non-fields as an index for the AA. The hashing function for an empty struct always hashes exactly one byte. It seems this data is not always copied when assigning an empty struct. It probably requires the values to be passed on the stack. void foo() { int a; } struct NoField { //ubyte f; } void main() { foo(); NoField[2] fields = void; fields[0] = NoField(); import core.stdc.stdio; printf("%d\n", *(cast(ubyte*)&fields[0])); } -- You are receiving this mail because: You are watching all bug changes.