develooper Front page | perl.perl6.language | Postings from May 2005

Re: split /(..)*/, 1234567890

Thread Previous | Thread Next
From:
Autrijus Tang
Date:
May 12, 2005 18:20
Subject:
Re: split /(..)*/, 1234567890
Message ID:
20050513011951.GB50926@aut.dyndns.org
On Thu, May 12, 2005 at 08:33:40PM -0400, Rick Delaney wrote:
> Sorry if I'm getting ahead of the implementation but if it is returning
> $0 then shouldn't ref($0) return ::Rule::Result or somesuch?  It would
> just look like an ::Array::Const if you treat it as such.

...also note that the $0 here is $/[0], also known as Perl 5's $1...

Indeed, the entire match result, that is $/, will always be a
single ::Match object if a match succeeds.

Thanks,
/Autrijus/

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About