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
List.squish does not always return the first list element #3762
Comments
From @edwinstAccording to its definition, squish should always return at least the first list element in the result list, no matter what &with returns. Currently it can happen that squish returns an empty list if &with returns true on the first comparison: This is perl6 version 2015.03 built on MoarVM version 2015.03
This works with unique:
|
From @cokeOn Sat Mar 28 16:15:48 2015, esteiner wrote:
I don't see this in the synopses, but only in the test file, and it looks like the tests were originally added after this ticket was opened. Can we get a ruling as to whether this is required? (Or a pointer to something in the Syn?) -- |
The RT System itself - Status changed from 'new' to 'open' |
From @usev6On Thu Aug 27 03:06:07 2015, coke wrote:
I think the relevant sentence from S32/Containers.html is "Returns a list of values from the invocant/argument list AFAIU .squish is not meant to wipe out all values -- regardless of the For the records: :with was added to the design docs with commit ec1b7c619d |
1 similar comment
From @usev6On Thu Aug 27 03:06:07 2015, coke wrote:
I think the relevant sentence from S32/Containers.html is "Returns a list of values from the invocant/argument list AFAIU .squish is not meant to wipe out all values -- regardless of the For the records: :with was added to the design docs with commit ec1b7c619d |
From @usev6This works now (fixed with commit ): $ perl6-m -e '<a a>.squish(:with(-> $a, $b {1})).perl.say' The tests in S32-list/squish.t are passing now. I'm closing this ticket as 'resolved'. |
1 similar comment
From @usev6This works now (fixed with commit ): $ perl6-m -e '<a a>.squish(:with(-> $a, $b {1})).perl.say' The tests in S32-list/squish.t are passing now. I'm closing this ticket as 'resolved'. |
@usev6 - Status changed from 'open' to 'resolved' |
From @usev6Fix commit: 0921fa43f8 |
Migrated from rt.perl.org#124205 (status was 'resolved')
Searchable as RT124205$
The text was updated successfully, but these errors were encountered: