Repository navigation
Conversation
There was a problem hiding this comment.
It is always possible to return a view.
There was a problem hiding this comment.
Okay. I copied from transpose and thought it safer to keep the hedge until it could be confirmed.
There was a problem hiding this comment.
In that case, it sounds like transpose documentation should be fixed as well.
|
Is this correct for the current verson? I'm thinking of the comments at #5260. |
|
No it is not: This is easy to fix: in line 1425, replace the current with |
|
If we make this change, it needs to be mentioned in the 1.10 release notes, maybe in the compatibility section. |
|
So in no case is the array copied, but currently there are some cases where the input is returned without creating a new view. I don't see why making it always return a view would change any intentional behaviour, but it might be considered a bug-fix. |
|
You would be surprised how much code can break because it depends on such "features", often by accident ;) |
|
Yes, I already know to be surprised... But, really, users taking advantage of a no-op call to mutate the array attributes? |
|
Frankly, didn't hear complains about |
|
To be fair, it's about as likely in this case that there is code which On Tue, Nov 11, 2014 at 11:59 PM, seberg [email protected] wrote:
Nathaniel J. Smith |
|
@jnothman Could you make the change suggested by @jaimefrio. Always returning a view seems to be the consensus. |
|
Ah, yes, sorry I didn't get back on this. I hadn't been sure what the exact fix should be wrt dev comments above. I should have commented so, but I'm glad it's being fixed up in any case. |
No description provided.