-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Syntax for readonly and T #476
Labels
enhancement
Enhancement to language design
implementation/done
Implementation Done
lang
Relates to the Ballerina language specification
Milestone
Comments
jclark
added
enhancement
Enhancement to language design
lang
Relates to the Ballerina language specification
labels
Apr 5, 2020
A couple of questions to consider:
|
Current consensus is to use |
I think it might be possible to express lax static typing in terms of intersection. See #488. |
jclark
added a commit
that referenced
this issue
May 1, 2020
jclark
added a commit
that referenced
this issue
May 1, 2020
This is now done. |
Closed
jclark
added a commit
that referenced
this issue
May 1, 2020
This was referenced May 14, 2020
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
enhancement
Enhancement to language design
implementation/done
Implementation Done
lang
Relates to the Ballerina language specification
We need to a syntax to specify that something is readonly and belongs to type T.
The immutability proposal uses
readonly<T>
.Another approach is to add intersection types using
&
as the intersection operator, so you would sayreadonly & T
.This is part of #189.
The text was updated successfully, but these errors were encountered: