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

RFC: extend unsafe_assign to work for any isbits type, add pointer_from_objref #2515

Merged
merged 3 commits into from
Mar 8, 2013

Conversation

stevengj
Copy link
Member

@stevengj stevengj commented Mar 8, 2013

The attached patch modifies the pointerset and pointerref intrinsics to check isbits rather than is_bitstype, so that they use the same code for any pointer-free immutable type.

It also adds a pointer_from_objref function which is the inverse of unsafe_pointer_to_objref.

Both of these functions are motivated by the desire to be able to store jl_value_t* pointers in a C struct given a pointer to the latter, as discussed on julia-dev.

JeffBezanson added a commit that referenced this pull request Mar 8, 2013
RFC: extend unsafe_assign to work for any isbits type, add pointer_from_objref
@JeffBezanson JeffBezanson merged commit 645a65d into JuliaLang:master Mar 8, 2013
@stevengj stevengj mentioned this pull request Mar 16, 2013
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.

None yet

2 participants