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

test reduce aliasing arguments #66

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

haarg
Copy link
Member

@haarg haarg commented Jan 3, 2018

No description provided.

@haarg haarg mentioned this pull request Jan 3, 2018
@leonerd
Copy link
Contributor

leonerd commented Jan 5, 2018

I don't want to assert this in the tests because the documentation never states it. What it says is:

Reduces @list by calling "BLOCK" in a scalar context multiple times, setting $a and $b each time. The first call will be with $a and $b set to the first two elements of the list, subsequent calls will be done by setting $a to the result of the previous call and $b to the next element in the list.

It just uses the phrase "sets $b to ...", doesn't mention aliasing. The current implementation happens to alias but I don't want to guarantee that in future, as that's a fragile implementation detail that might change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants