Add ast2 union support

This commit is contained in:
Ganesh Viswanathan 2020-03-16 23:15:34 -05:00
commit 1a9911fc25
3 changed files with 76 additions and 13 deletions

View file

@ -71,4 +71,10 @@ assert A21 is A20
assert A21p is ptr A20
assert A22 is object
testFields(A22, {"f1": "ptr ptr cint", "f2": "array[0..254, ptr cint]"}.toTable())
testFields(A22, {"f1": "ptr ptr cint", "f2": "array[0..254, ptr cint]"}.toTable())
assert U1 is object
assert sizeof(U1) == sizeof(cfloat)
assert U2 is object
assert sizeof(U2) == 256 * sizeof(cint)