Skip to content

Arithmetic operations B @ A are now only implemented for owned storage B #93

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

Merged
merged 4 commits into from
Feb 28, 2016

Conversation

bluss
Copy link
Member

@bluss bluss commented Feb 28, 2016

Please see the Arithmetic Operations overview in the ArrayBase docs
for an easy to read overview.

Fixes #83

…e `B`

Previously, operators like +, - etc, denoted by @ in general, were
implemented so that they allowed ArrayViewMut as the left hand side
operand. It would update the data in the view, and return the same view.

This can be confusing, and was suggested by @SuperFluffy to be removed.

We tentatively remove those implementations here.

To work around B @ A not being allowed for a mutable view `B`, you can
use B @= A instead, or the corresponding stable methods iadd, imul, etc.

Please see the Arithmetic Operations overview in the `ArrayBase` docs
for an easy to read overview.

Fixes #83
bluss added a commit that referenced this pull request Feb 28, 2016
Arithmetic operations B @ A are now only implemented for owned storage `B`
@bluss bluss merged commit a08b1fd into master Feb 28, 2016
@bluss bluss deleted the no-arrayviewmut-arithmetic branch February 28, 2016 18:33
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.

1 participant