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

Allow custom opaque functions #75

Merged
merged 6 commits into from
Aug 29, 2023
Merged

Allow custom opaque functions #75

merged 6 commits into from
Aug 29, 2023

Conversation

samestep
Copy link
Contributor

@samestep samestep commented Aug 29, 2023

This PR adds a custom function to construct opaque functions that simply call an arbitrary JavaScript function. To achieve this, the rose::FuncNode trait has been split into a rose::Refs trait and a rose::Node enum, the latter of which has two cases for the previously-existing Transparent functions and the new Opaque functions.

This initial implementation only supports opaque functions with very simple signatures: a small number of F64 parameters, and an F64 return value.

@samestep samestep marked this pull request as ready for review August 29, 2023 19:50
@samestep samestep merged commit 2c23c1d into main Aug 29, 2023
2 checks passed
@samestep samestep deleted the custom branch August 29, 2023 19:54
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