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

Stash.new creates Hash, not a Stash #3137

Closed
p6rt opened this issue May 17, 2013 · 7 comments
Closed

Stash.new creates Hash, not a Stash #3137

p6rt opened this issue May 17, 2013 · 7 comments

Comments

@p6rt
Copy link

p6rt commented May 17, 2013

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

Searchable as RT118029$

@p6rt
Copy link
Author

p6rt commented May 17, 2013

From @lizmat

11​:27​:12] <lizmat> rn​: my $s=Stash.new; say $s.WHAT
[11​:27​:15] <+camelia> rakudo 570d1d​: OUTPUT«(Hash)␤»
[11​:27​:15] <+camelia> ..niecza v24-51-g009f999​: OUTPUT«(Stash)␤»
[11​:27​:34] <lizmat> this means I can't use Stash as a parameter constraint :-(
[11​:28​:20] <lizmat> r​: sub S (Stash $s) { say $s }; S(Stash.new) # rakudobug?
[11​:28​:21] <+camelia> rakudo 570d1d​: OUTPUT«Nominal type check failed for parameter '$s'; expected Stash but got Hash instead␤ in sub S at /tmp/ep3aQw5kNa​:1␤ in block at /tmp/ep3aQw5kNa​:1␤␤»
[11​:28​:45] <moritz> yes, Stash.new should produces a Stash, not a Hash
[11​:29​:40] lizmat submist rakudobug

@p6rt
Copy link
Author

p6rt commented Nov 14, 2013

From @lizmat

Seems to be fixed.

@p6rt
Copy link
Author

p6rt commented Nov 14, 2013

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

@p6rt
Copy link
Author

p6rt commented Oct 15, 2014

From @usev6

I added tests to S02-types/declare.t and S02-types/stash.t with the following commit​: Raku/roast@658c9604e7

Since the latter file is not yet included in Rakudo's t/spectest.data I'll leave the ticket open until that is done.

1 similar comment
@p6rt
Copy link
Author

p6rt commented Oct 15, 2014

From @usev6

I added tests to S02-types/declare.t and S02-types/stash.t with the following commit​: Raku/roast@658c9604e7

Since the latter file is not yet included in Rakudo's t/spectest.data I'll leave the ticket open until that is done.

@p6rt
Copy link
Author

p6rt commented Oct 16, 2014

From @usev6

S02-types/stash.t is now in Rakudo's t/spectest.data​: rakudo/rakudo@a6f181e7b0

@p6rt
Copy link
Author

p6rt commented Oct 16, 2014

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

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

No branches or pull requests

1 participant