val and var #12
Labels
Design document
This one came out from an idea but considers many cases and tries to prove the usabity
Syntax
This issue is about syntax
Milestone
About val
val
allows to make a readonly field/variable/property. Similar to what Kotlin has. It does not guarantee the structure being readonly, but the value itself is. Syntax:About var
var
is identical to C#'svar
. It is normally highlighted by the editor.Declaration:
Explicit type
Define it after
:
Unresolved
Should we make reassignment more explicit, like this:
or more "usual", like this:
The text was updated successfully, but these errors were encountered: