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

Expand simple let #30

Merged
merged 9 commits into from
Sep 11, 2021
Merged

Expand simple let #30

merged 9 commits into from
Sep 11, 2021

Conversation

certainty
Copy link
Owner

@certainty certainty commented Sep 11, 2021

Add expansion for let syntax to the expander. To make this work I started to add the macro expansion facility.
It uses the VM to expand the supplied syntax and thus forms the skeleton for user-defined syntax.
However it currently doesn't take care of hygiene (not required so far) and is probably not supporting all cases yet.

It adds an expander for a simple let, which expands into the corresponding lambda expressions.
At a later point I'll think about whether it's preferable to compile let expressions differently, which would required to preserve them and parse them into an expression.

Important

This doesn't implement named let as that requires a proper implementation of letrec first

@certainty certainty changed the title Expand let Expand simple let Sep 11, 2021
@certainty certainty merged commit 1d0694c into main Sep 11, 2021
@certainty certainty deleted the expand-let branch September 11, 2021 13:58
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.

1 participant