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

Cleanup: improve invocation codegen #540

Merged
merged 1 commit into from
Jan 18, 2025
Merged

Cleanup: improve invocation codegen #540

merged 1 commit into from
Jan 18, 2025

Conversation

kengorab
Copy link
Owner

Previously there was a lot of logic involved in the compiler when performing codegen for invocation expressions, particularly in the case of invoking an expression value (aka, a function value). This change abstracts that complex logic out into a generated #call method for the adhoc "Function" structs, and it also cleans it up a bunch too. Additionally, the logic in the main codegen function for invocation expressions gets significantly cleaner.

Previously there was a lot of logic involved in the compiler when
performing codegen for invocation expressions, particularly in the case
of invoking an expression value (aka, a function value). This change
abstracts that complex logic out into a generated `#call` method for the
adhoc "Function" structs, and it also cleans it up a bunch too.
Additionally, the logic in the main codegen function for invocation
expressions gets significantly cleaner.
@kengorab kengorab merged commit c63c53f into master Jan 18, 2025
1 check passed
@kengorab kengorab deleted the call-method branch January 18, 2025 02:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant