add test case to cover already-solved bug

closes #2401
This commit is contained in:
Andrew Kelley 2020-01-05 17:42:03 -05:00
parent 6ff70d3c31
commit c30106c906
No known key found for this signature in database
GPG Key ID: 7C5F548F728501A9

View File

@ -611,3 +611,12 @@ test "function call result coerces from tagged union to the tag" {
S.doTheTest();
comptime S.doTheTest();
}
test "0-sized extern union definition" {
const U = extern union {
a: void,
const f = 1;
};
expect(U.f == 1);
}