Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

[perl #70293] [BUG] :repl in pick should be called :replace

0 views
Skip to first unread message

Carl Mäsak

unread,
Nov 6, 2009, 9:55:51 AM11/6/09
to bugs-bi...@netlabs.develooper.com
# New Ticket Created by "Carl Mäsak"
# Please include the string: [perl #70293]
# in the subject line of all future correspondence about this issue.
# <URL: http://rt.perl.org/rt3/Ticket/Display.html?id=70293 >


<pmichaud> rakudo: say (1..4).pick(10, :replace)
<p6eval> rakudo 5e05b8: OUTPUT«4123␤»
<pmichaud> okay, that's a bug
<Wolfman2000> ...only picked 4
<pmichaud> or maybe it's still :repl
* masak submits
<pmichaud> rakudo: say (1..4).pick(10, :repl)
<p6eval> rakudo 5e05b8: OUTPUT«4111132243␤»
<pmichaud> there
<pmichaud> rakudo: say (1..4).pick(10)
<p6eval> rakudo 5e05b8: OUTPUT«2413␤»
<Wolfman2000> what is repl supposed to do versus replace?
<masak> pmichaud: is :replace specced?
<pmichaud> an earlier version of the spec had the option as ":repl"
instead of ":replace"
<PerlJam> Wolfman2000: repl is supposed to be spelt replace :)
<pmichaud> I'm thinking rakudo hasn't switched to the new option name
<masak> pmichaud: I still see :$repl in S32.
<pmichaud> perhaps S32 hasn't been updated either, then
<pmichaud> I know that we expressed that we wanted it to change at some point
<pmichaud> I don't believe we decided that it should be :repl instead
of :replace though
<masak> pmichaud: I don't see :replace anywhere in the spec.
<PerlJam> (anyway, /me is completely against cryptic named parameters.
We have the technology and space for the few extra characters that
would make thing clearer)
<pmichaud> PerlJam: I agree, which is why I thought we had changed it
to :replace already
<pmichaud> http://irclog.perlgeek.de/perl6/2009-07-07#i_1296482 #
discussion about :repl and :replace
<pmichaud> if someone wants to update S32, that would be awesome.
<masak> I'll make sure RT has a ticket about it, anyway.
<pmichaud> I can always count on you, masak++ :)

0 new messages