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

do not store all of ErlNifTerm in Binary struct #488

Closed
wants to merge 1 commit into from

Conversation

hansihe
Copy link
Member

@hansihe hansihe commented Sep 12, 2022

This change enables us to not call enif_inspect_binary when creating subbinaries.

@filmor
Copy link
Member

filmor commented Sep 13, 2022

I rebased #487 on this one, is there a particular reason why you used *mut u8 instead of *const u8 here?

@hansihe
Copy link
Member Author

hansihe commented Sep 13, 2022

@filmor I did it to avoid the cast when getting the pointer from the ErlNifBinary.

In retrospect it is probably a good idea to do the cast there in order to have the type be more descriptive in the struct.

@hansihe
Copy link
Member Author

hansihe commented Sep 13, 2022

Included in #487

@hansihe hansihe closed this Sep 13, 2022
@filmor filmor deleted the hans/binary_no_erlnifbinary branch September 13, 2022 08:43
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