You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is of course more advanced that the proposed and might be a good idea to have it at least in the plan even if it is not supported from the beginning.
For example, below is a snippet in scala that defines a generic union type where some variants implement a different concrete instance of that generic union type.
There is plenty of information available when this is considered a good model and when not so i don't think it is useful to repeat this here. But believe if it is not included in the "vision" it can never be part of the language.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
The TypeUnions proposal seems to cover a lot of scenarios.
But I am not seeing that it supports Generalized Algebraic Data Types
This is of course more advanced that the proposed and might be a good idea to have it at least in the plan even if it is not supported from the beginning.
For example, below is a snippet in scala that defines a generic union type where some variants implement a different concrete instance of that generic union type.
There is plenty of information available when this is considered a good model and when not so i don't think it is useful to repeat this here. But believe if it is not included in the "vision" it can never be part of the language.
Beta Was this translation helpful? Give feedback.
All reactions