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

[Compiler+VM POC] Add compilation for inherited pre/post conditions #3729

Draft
wants to merge 1 commit into
base: supun/func-conditions
Choose a base branch
from

Conversation

SupunS
Copy link
Member

@SupunS SupunS commented Jan 16, 2025

Depends on #3727 and #3728

Description

Similar to default functions (#3727), inherited function pre/post conditions are also copied over at AST level. Once they are copied over, they get compiled similar to normal inlined pre-post conditions (#3728)


  • Targeted PR against master branch
  • Linked to Github issue with discussion and accepted design OR link to spec that describes this work
  • Code follows the standards mentioned here
  • Updated relevant documentation
  • Re-reviewed Files changed in the Github PR explorer
  • Added appropriate labels

@SupunS SupunS added the Feature label Jan 16, 2025
@SupunS SupunS self-assigned this Jan 16, 2025
Comment on lines +419 to +422
// TODO: Merge this elaboration with the current elaboration (d.elaboration).
// Because the inherited functions need their corresponding elaboration
// for code generation.
elaboration, err := d.config.ElaborationResolver(interfaceType.Location)
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suffers from the same problem as default-functions. Need to figure out a way to universally solve this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant