-
Notifications
You must be signed in to change notification settings - Fork 53
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
Fix closure representation in the Nock backend #3105
Conversation
9895cb8
to
b723a5e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible to add additional tests that use currying that would have failed with the previous approach?
The old way of handling closures is correct "internally" -- as long as we're using the old closure calling convention everywhere. The problem is that the old calling convention doesn't match the Nock calling convention, so it would crash if a partially applied function is called externally by Nock. But we're not testing against the actual Nock interpreter right now, so it's hard to add a new test for that. This is partially tested in |
This makes sense thanks. |
The representation of closures is changed to make it more efficient and compatible with the Nock calling convention.