This now type checks. It's starting to feel real... union IntOrPtr { i: int; p: int*; } var u1 = IntOrPtr{i = 42} var u2 = IntOrPtr{p = cast(int*, 42)} var a: int[256] = {1, 2, ['a'] = 3}
-
-
An intentional design constraint is to follow C wherever reasonable. But thanks. :)
-
The constraint is not to "improve" C except where it makes the compiler easier to implement (I would happily have implemented a C99 compiler if C had less issues when it comes to parsing, the preprocessor, etc).
- 2 more replies
New conversation -
-
-
This Tweet is unavailable.
-
Putting type symbols on the left and access symbols on the left creates a symmetry between “definition by type” and “definition by example”: x:^int # x is a pointer to an int x^:int # x dereferenced is an int f:int->int f(x:int):int
- 1 more reply
-
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.