-
-
Notifications
You must be signed in to change notification settings - Fork 13
Slices should return views, not copies #8
Copy link
Copy link
Closed
Labels
featureNew feature or requestNew feature or requestimportantIssues that should be addressed soon.Issues that should be addressed soon.
Description
This is a hard one. Current NDArray already uses shared_ptr for other reasons, but every NDArray would have to keep track of its particular view into the array as well.
This might be possible by keeping a tuple of 'view semantics', which will be passed to xtv functions when set. Subsequent views would have to be concatenated into the first, probably requiring a special function, but it should be possible. Besides, just single-level views would already be tremendously useful on their own.
Alternatively, it might be possible to adapt xarray to make a custom subclass that already keeps track of strides. This might be considerably harder though.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
featureNew feature or requestNew feature or requestimportantIssues that should be addressed soon.Issues that should be addressed soon.