Skip to content

Commit

Permalink
one-arg say should just gist it
Browse files Browse the repository at this point in the history
A function that distributes .gist over all its arguments should not
make an exception when there's only one argument.
  • Loading branch information
TimToady committed Aug 29, 2015
1 parent 287360b commit eac8b76
Showing 1 changed file with 0 additions and 10 deletions.
10 changes: 0 additions & 10 deletions src/core/io_operators.pm
Original file line number Diff line number Diff line change
Expand Up @@ -22,16 +22,6 @@ multi sub say(Str:D \x) {
my str $str = nqp::concat(nqp::unbox_s(x),$out.nl);
$out.print($str);
}
multi sub say(Mu:D \args) {
my $out := $*OUT;
my str $str;
my \iterator := nqp::istype(args, Iterable) ?? args.iterator !! args.list.iterator;
until (my \value := iterator.pull-one) =:= IterationEnd {
$str = nqp::concat($str,nqp::unbox_s(value.gist));
}
$str = nqp::concat($str,$out.nl);
$out.print($str);
}
multi sub say(**@args is rw) {
my $out := $*OUT;
my str $str;
Expand Down

0 comments on commit eac8b76

Please sign in to comment.