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

Support extensions #21

Open
MaxDesiatov opened this issue Jun 5, 2019 · 0 comments
Open

Support extensions #21

MaxDesiatov opened this issue Jun 5, 2019 · 0 comments
Assignees
Projects

Comments

@MaxDesiatov
Copy link
Owner

MaxDesiatov commented Jun 5, 2019

While all extensions would be merged into the same environment during typechecking, AST should have a separate type for extension nodes. Existence of members in the main type declaration, as compared to extension members, triggers different semantic checks, e.g. synthesized memberwise initializers etc. Besides, extensions can have predicates on them, which would also be represented on extension AST nodes.

This issue also requires the environment "transformer" mentioned in #19, that converts AST to environment, should also take extensions into account somehow. Maybe there should be a separate Environment type with mutating functions that can consume AST and modify the environment during AST traversal?

@MaxDesiatov MaxDesiatov self-assigned this Jun 5, 2019
@MaxDesiatov MaxDesiatov added this to To do in 0.1 release via automation Jun 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
0.1 release
  
To do
Development

No branches or pull requests

1 participant