Skip to content
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

[LOWPRI] Unify class "instance types" with anonymous object types. #42

Open
jordwalke opened this issue Jan 14, 2016 · 0 comments
Open
Labels
KIND: FEATURE REQUEST Parser parsing reason code into an AST

Comments

@jordwalke
Copy link
Member

There is a totally different syntax for anonymous object types and class instance types:
(Ptyp_object and Pcty_sig respectively). One is used to define types of object without knowing their classes, and the other is to define the return value of a constructor ("instance types"). They are unified by the type system seamlessly, but their type definitions use a different syntax.
I'm in the middle of sending out a parser update that improves them independently but they are not unified yet. There's no reason why they can't be unified, as the Ptyp_object syntactically only includes methods, whereas Pcty_sig includes that and much more. Just one more thing that unnecessarily gives objects a bad reputation.

@jordwalke jordwalke changed the title Unify class "instance types" with anonymous object types. [LOWPRI] Unify class "instance types" with anonymous object types. Jan 14, 2016
@jaredly jaredly added KIND: FEATURE REQUEST Parser parsing reason code into an AST labels Jun 14, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
KIND: FEATURE REQUEST Parser parsing reason code into an AST
Projects
None yet
Development

No branches or pull requests

2 participants