-
Notifications
You must be signed in to change notification settings - Fork 28
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
assert that input and output buffers passed to transcode! are independent #140
Conversation
This is a good basic check, but I think we might want to actually check for aliasing. The help?> Base.dataids
Base.dataids(A::AbstractArray)
Return a tuple of UInts that represent the mutable data segments of an array.
Custom arrays that would like to opt-in to aliasing detection of their component parts can specialize this method to
return the concatenation of the dataids of their component parts. A typical definition for an array that wraps a
parent is Base.dataids(C::CustomArray) = dataids(C.parent). For normal arrays, it seems
|
Co-authored-by: Mark Kittisopikul <mkitti@users.noreply.github.com>
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.
Thanks! Can we add a quick test too?
@timholy just referred me to
|
I wonder if we are going to need an |
Agreed, added. |
4f2339d
to
7e8b77b
Compare
7e8b77b
to
2eec770
Compare
As suggested by @quinnj in #136 (comment)