Re: splatting a reference

2003-12-13 Thread Larry Wall
On Sat, Dec 13, 2003 at 11:04:57PM +0100, Stéphane Payrard wrote: : On Sat, Dec 13, 2003 at 12:12:59PM -0800, Larry Wall wrote: : > : > print $ref : > : > it doesn't do what you want, but : > : > print $ref.as(Array) : > : > might work a lot better, though of course : > : > print @

Re: enums and bitenums

2003-12-13 Thread Larry Wall
On Sat, Dec 13, 2003 at 03:43:00PM -0800, Paul Hodges wrote: : Amen, brutha. Accordingly, do we have an idea what it actually means to : add a type to something? I mean, I get that we could say : : print "yup" if $Spot ~~ AttackDog; : : but is there still : : print ref $Spot; : : and if so

Re: enums and bitenums

2003-12-13 Thread Paul Hodges
--- Larry Wall <[EMAIL PROTECTED]> wrote: > On Sat, Dec 13, 2003 at 07:16:21AM -0800, Paul Hodges wrote: > : $Spot = $visitor.nephew ?? $nicedog :: $meandog; > : > : Which brings up a small side note: that's a successfully applied > : boolean context for $visitor.nephew, right? > > Yes, but $v

splatting a reference

2003-12-13 Thread Stéphane Payrard
On Sat, Dec 13, 2003 at 12:12:59PM -0800, Larry Wall wrote: > > print $ref > > it doesn't do what you want, but > > print $ref.as(Array) > > might work a lot better, though of course > > print @$ref > What is supposed to do the splat operator in this context? My understanding is

Re: Vocabulary

2003-12-13 Thread Larry Wall
On Sat, Dec 13, 2003 at 12:50:50PM -0500, Austin Hastings wrote: : > -Original Message- : > From: Larry Wall [mailto:[EMAIL PROTECTED] : > Sent: Friday, December 12, 2003 8:30 PM : : > On Fri, Dec 12, 2003 at 05:17:37PM -0500, Austin Hastings wrote: : > : I presume that the linear order (c

Re: enums and bitenums

2003-12-13 Thread Larry Wall
On Sat, Dec 13, 2003 at 07:16:21AM -0800, Paul Hodges wrote: : $Spot = $visitor.nephew ?? $nicedog :: $meandog; : : Which brings up a small side note: that's a successfully applied : boolean context for $visitor.nephew, right? Yes, but $visitor.nephew is no longer .does(nephew) in my current vi

Re: enums and bitenums

2003-12-13 Thread Larry Wall
On Sat, Dec 13, 2003 at 12:22:00PM -0500, Austin Hastings wrote: : > We might be able to make it work, though as you say, there are other : > ways to get there, and the chances are that at least one of them will : > be a better way. Certainly when the Dog object's class is composed, it : > will ha

Re: enums and bitenums

2003-12-13 Thread Larry Wall
On Sat, Dec 13, 2003 at 01:42:58PM +, Andy Wardley wrote: : How about a single colon? : : Color:green Vaguely possible, but the lexer would have to distinguish Color:green Color: green Color :green It may yet do that, but probably not for this reason. : This is the same s

Re: Vocabulary

2003-12-13 Thread Larry Wall
On Sat, Dec 13, 2003 at 12:07:40PM -0500, Austin Hastings wrote: : > From: Larry Wall [mailto:[EMAIL PROTECTED] : > The behavior probably doesn't expire unless you've cloned the object : > and the clone expires. However, if a role goes out of its lexical : > scope, it can't be named, so it's effec

Re: Roles and Mix-ins?

2003-12-13 Thread Larry Wall
On Sat, Dec 13, 2003 at 04:57:17AM -0700, Luke Palmer wrote: : Chris Shawmail (E-mail) writes: : > I'm still digesting the vocabulary thread, but while I do, let me ask a : > question that's probably crystal clear to everyone else. : > : > Do roles act as a form of mix-in, as Ruby modules may, and

RE: enums and bitenums

2003-12-13 Thread Austin Hastings
> -Original Message- > From: Luke Palmer [mailto:[EMAIL PROTECTED] > Sent: Saturday, December 13, 2003 9:30 AM > To: Andy Wardley; Larry Wall; Perl6; [EMAIL PROTECTED] > Subject: Re: enums and bitenums > > > Andy Wardley writes: > > Larry Wall wrote: > > > Well, we can't use -> because

RE: Vocabulary

2003-12-13 Thread Austin Hastings
> -Original Message- > From: Larry Wall [mailto:[EMAIL PROTECTED] > Sent: Friday, December 12, 2003 8:30 PM > On Fri, Dec 12, 2003 at 05:17:37PM -0500, Austin Hastings wrote: > : Good. I like the mixin being available at either time. This > makes properties > : a lot more useful since I

RE: enums and bitenums

2003-12-13 Thread Austin Hastings
> -Original Message- > From: Larry Wall [mailto:[EMAIL PROTECTED] > Sent: Friday, December 12, 2003 7:39 PM > To: Perl6 > Subject: Re: enums and bitenums > > > On Fri, Dec 12, 2003 at 03:10:30PM -0800, Paul Hodges wrote: > : Ok, wait a sec. Does that mean different references to the same

RE: Vocabulary

2003-12-13 Thread Austin Hastings
> From: Larry Wall [mailto:[EMAIL PROTECTED] > > On Fri, Dec 12, 2003 at 04:27:59PM -0500, Austin Hastings wrote: > : > -Original Message- > : > From: Jonathan Scott Duff [mailto:[EMAIL PROTECTED] > : > I think I'm getting it but I'm not sure. Does something like this > : > work? > : > > :

Re: enums and bitenums

2003-12-13 Thread Paul Hodges
--- Larry Wall <[EMAIL PROTECTED]> wrote: > On Fri, Dec 12, 2003 at 03:10:30PM -0800, Paul Hodges wrote: > : Ok, wait a sec. Does that mean different references to the same > : critter can have differing sets of aspects? > : > : my Dog $Spot; > : my $doggie = Dog.new(); > : my $meando

Re: enums and bitenums

2003-12-13 Thread Luke Palmer
Andy Wardley writes: > Larry Wall wrote: > > Well, we can't use -> because we're using that for something else. > > But it's certainly true that we'll have to have some mechanism for > > disambiguating Color.green from Blackberry.green. After all, > > > > Blackberry.green == Color.red > > >

Re: enums and bitenums

2003-12-13 Thread Andy Wardley
Larry Wall wrote: > Well, we can't use -> because we're using that for something else. > But it's certainly true that we'll have to have some mechanism for > disambiguating Color.green from Blackberry.green. After all, > > Blackberry.green == Color.red > > Or maybe it's > > Blackberry::

Re: Roles and Mix-ins?

2003-12-13 Thread Luke Palmer
Chris Shawmail (E-mail) writes: > I'm still digesting the vocabulary thread, but while I do, let me ask a > question that's probably crystal clear to everyone else. > > Do roles act as a form of mix-in, as Ruby modules may, and Objective-C > protocols do? > > Would the following two snippets be a

Roles and Mix-ins?

2003-12-13 Thread Chris Shawmail (E-mail)
I'm still digesting the vocabulary thread, but while I do, let me ask a question that's probably crystal clear to everyone else. Do roles act as a form of mix-in, as Ruby modules may, and Objective-C protocols do? Would the following two snippets be at all equivalent? # Perl6 role Talk { meth