Re: Trimming arrays

2009-01-13 Thread Aristotle Pagaltzis
* Ovid publiustemp-perl6langua...@yahoo.com [2009-01-13 00:35]: * Larry Wall la...@wall.org [2009-01-13 00:25]: It should probably say No such method. We have hyperops now to apply scalar operators to composite values explicitly: @array».=trim Won't that fail with 'No such method' on

Re: Trimming arrays

2009-01-13 Thread Patrick R. Michaud
On Mon, Jan 12, 2009 at 03:30:05PM -0800, Ovid wrote: From: Larry Wall la...@wall.org : my @array = ' foo ', ' bar '; : @array .= trim; : say @array.perl; : : And what if I have an array of hashes of hashes of arrays? : : Currently you can call 'trim' on arrays, but

Re: Trimming arrays

2009-01-13 Thread Moritz Lenz
Ovid wrote: What should this output? my @array = ' foo ', ' bar '; @array .= trim; say @array.perl; And what if I have an array of hashes of hashes of arrays? Currently you can call 'trim' on arrays, but it's a no-op. Similar issues with chomp and friends. I think

Re: Trimming arrays

2009-01-13 Thread Patrick R. Michaud
On Tue, Jan 13, 2009 at 08:19:25AM -0600, Patrick R. Michaud wrote: @array».=trim Won't that fail with 'No such method' on an array of hashes? Or are hyperops applied recursively? I would expect this to be roughly equivalent to: for @array { $_ .= trim; } For an array

Re: [PATCH] Add .trim method

2009-01-13 Thread Brandon S. Allbery KF8NH
On 2009 Jan 12, at 15:17, Ovid wrote: בָּרוּךְ שֵׁם כְּבוֹד מַלְכוּתוֹ לְעוֹלָם וָעֶד. If you can't see that in your client, that's Hebrew from http://www.i18nguy.com/unicode/shma.html and means Hear O Israel, the Lord is our God, the Lord is One. Actually that's the

r24895 - docs/Perl6/Spec

2009-01-13 Thread pugs-commits
Author: lwall Date: 2009-01-13 20:30:15 +0100 (Tue, 13 Jan 2009) New Revision: 24895 Modified: docs/Perl6/Spec/S03-operators.pod docs/Perl6/Spec/S06-routines.pod Log: [S03] remove .contains fossil Modified: docs/Perl6/Spec/S03-operators.pod