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

Float and Uniform array support #61

Merged
merged 2 commits into from
Jan 28, 2024

Conversation

mt-caret
Copy link
Contributor

@mt-caret mt-caret commented Jan 27, 2024

This PR adds support for uniform arrays (i.e. arrays where elements are guaranteed to be boxed) and floatarrays (unboxed float arrays). Bumps the version of ocaml-sys so we can use caml_sys_double_field and the like.

This sidesteps the issue of supporting arrays in general where it's pretty painful to dispatch to the correct type in Rust when seeing the double array tag since it's somewhat non-trivial to specialize traits based on whether the OCaml type is OCamlFloat/f64.

@tizoc
Copy link
Owner

tizoc commented Jan 28, 2024

@mt-caret thank you! It looks good. Is it ready for merging as-is ?

@mt-caret
Copy link
Contributor Author

Hey, thanks! Yup, both PRs are ready to merge.

@tizoc tizoc merged commit 0588ba3 into tizoc:master Jan 28, 2024
3 checks passed
@mt-caret mt-caret deleted the uniform-and-float-arrays branch January 28, 2024 14:40
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