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

Grabbing or picking NaN elements from a BagHash should not work (say ^5 .BagHash.pick(NaN)) #6227

Closed
p6rt opened this issue May 8, 2017 · 4 comments

Comments

@p6rt
Copy link

p6rt commented May 8, 2017

Migrated from rt.perl.org#131270 (status was 'resolved')

Searchable as RT131270$

@p6rt
Copy link
Author

p6rt commented May 8, 2017

From @AlexDaniel

Code​:
my $x = (^5).BagHash;
say $x.grab(NaN);
say $x

Result​:
[1 2 3 0 4]
BagHash.new()

In other words, it works like if you grabbed ∞ or *. It should probably error out in some way.

@p6rt
Copy link
Author

p6rt commented May 8, 2017

From @zoffixznet

On Mon, 08 May 2017 06​:05​:36 -0700, alex.jakimenko@​gmail.com wrote​:

Code​:
my $x = (^5).BagHash;
say $x.grab(NaN);
say $x

Result​:
[1 2 3 0 4]
BagHash.new()

In other words, it works like if you grabbed ∞ or *. It should
probably error out in some way.

Thank you for the report. This is now fixed.

Fix​: rakudo/rakudo@60f898194f
Tests​: Raku/roast@b6073e1782

@p6rt
Copy link
Author

p6rt commented May 8, 2017

The RT System itself - Status changed from 'new' to 'open'

@p6rt p6rt closed this as completed May 8, 2017
@p6rt
Copy link
Author

p6rt commented May 8, 2017

@zoffixznet - Status changed from 'open' to 'resolved'

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

No branches or pull requests

1 participant