Re:Show HN: A new programming language inspired by Go, no LLVM
by RadiozRadioz on Sunday June 01, 2025 @04:32AM
(#44149452)
Can you explain what is odd about this? I think it seems perfectly logical.
The tuple type definition _looks_ like how the tuple will look. The nullable indicator is a symbol with a delightfully appropriate semantic meaning.
Re:Show HN: A new programming language inspired by Go, no LLVM
by hualaka on Sunday June 01, 2025 @07:27AM
(#44150110)
? Commonly used for nullable types.
The tup is an interesting question. I often think about tup(int, bool, string) vs (int, bool, string). I convince myself that there might be a better choice.
`var t = (1 as i8, true, false)` Use automatic inference to replace active type declarations.
t.0 vs t[0] is equally difficult to choose, but t[0] is the more commonly used syntax. Using t[n] consistently across map/vec/set/tup might be the more correct decision.
(int,bool,bool) t = (1, true, false) // v: Define a tuple. Access elements using t[0], t[1], t[2]
string? s = null