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
Wow, I had no idea we could even use #polymorphic-type in a pattern match!
I see the motivation here. We should come up with a consistent language for representing row-polymorphic types and then try to use that in this case. It's likely not going to be the *. Perhaps your goal was merely to get it out of the syntactic real estate quickly so that we could use # for polymorphic variants? The syntax for polymorphic pattern type match likely should match the syntax for class types which also use the #. If we change one we should probably change the other.
Yes, the idea is to make it possible to use # for polymorphic variants. This PR was mostly to start the discussion on how to solve this. I see class types as something different though and from my understanding it's not related. Actually for this change I think we should focus on polymorphic variants instead. In that sense it should be somewhat related to the # that is being proposed, or we need to choose a different syntax.
see class types as something different though and from my understanding it's not related.
You may wish to read up on the object system and class types. Polymoprhic variants and objects are actually very much related and it was a very enlightening learning experience to discover the connection.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #578.
Also related to #366