Re: Two questions on Perl 6 functionality

2010-06-20 Thread Xi Yang
I still have several points unclear, this is my sample: ### class Base { method toHash() { return {}; } } role FooBar { has $.foo is rw; has $.bar is rw; toHash.wrap({ my $hash = callsame(); $hash = $self.foo;

RE: Two questions on Perl 6 functionality

2010-06-20 Thread Xi Yang
Very subtle implementation, I'm trying to understand those things. Thanks! > Date: Sun, 20 Jun 2010 13:53:59 +0200 > From: mor...@faui2k3.org > To: jianding...@msn.com > CC: perl6-users@perl.org > Subject: Re: Two questions on Perl 6 functionality > > > > Xi Yang wrote: > > You might mis-unders

RE: Two questions on Perl 6 functionality

2010-06-20 Thread Xi Yang
You might mis-understood method modifiers. I mean: before x() after x() around x() > Date: Sun, 20 Jun 2010 12:17:46 +0200 > From: mor...@faui2k3.org > To: jianding...@msn.com > CC: perl6-users@perl.org > Subject: Re: Two questions on Perl 6 functionality > > Hi, > > Xi Yang wrote: > > 1: