-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Labels
Description
We allow positional fields in named product types, but there's no way to select the fields without pattern matching:
type Foo(U32)
main():
let x = Foo(123)
let fieldValue = match x:
Foo(x): x
We also don't have destructuring syntax, so we have to use a match
just to select the fields which is verbose.
We should use the same syntax as Rust: .0
, .1
, ... for the positional fields.