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

Introduce dynamic fns #664

Merged
merged 2 commits into from
Feb 7, 2020
Merged

Conversation

hellerve
Copy link
Member

@hellerve hellerve commented Feb 7, 2020

This PR introduces dynamic fn constructs, including closures. It seems to work fairly well, although I’m not quite happy with the implementation.

Eventually, while refactoring evaluation, I’d like to opt for introducing a more generic and powerful construct for this: Closure Env Obj. This would be part of Obj and able to wrap any other object with an environment that it closes over. That’s a little more principled and beautiful, but also more work that I’d hate to invest while we’re still working on a system that will get replaced.

Cheers

@eriksvedang eriksvedang merged commit 954c9b9 into carp-lang:master Feb 7, 2020
@hellerve hellerve deleted the veit/dynamic-fn branch February 7, 2020 21:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants