Apocalypse 12, RFC 254

April 18th, 2004 11:56 PM

I haven’t finished reading all 20 pages (twenty!), but Apocalypse 12 is out detailing the object system design of Perl 6. I was somewhat surprised to see that my RFC 254, Class Collections: Provide the ability to overload classes, was included with a PSA of “abb” (Problem “Accepted wholeheartedly”, Solution and Acceptance “Accepted with a few ‘buts’”). It seems like ages ago that I wrote that RFC; I remember writing it from the brand new Cnation offices in the Fall of 2000, but it seems like I was a different person back then. Amazing how time flies.

There’s probably more about it later in the Apocalypse, but the first reference to the issue is on page 3:

Where possible, class names are treated polymorphically, just as method names are. This powerful feature makes it possible to inherit systems of classes in parallel. (These classes might be inner classes, or they might be inner aliases to outer classes.) By making the class names “virtual”, the base classes can refer to the appropriate derived classes without knowing their full name. That sounds complicated, but it just means that if you do the normal thing, Perl will call the right class instead of the one you thought it was going to call. :-)

At least I think that’s referring to my RFC. The Apocalypse is so dense, I’m often not entirely sure what’s going on. Some of it has the frightening edge of unfamiliarity, such as this gem:

In other words, Perl 6 distinguishes:

$obj.method ($x + $y) + $z # means $obj.method(($x + $y) + $z)


$obj.method($x + $y) + $z # means ($obj.method($x + $y)) + $z

Yes, this is different from Perl 5. And yes, I know certain people hate it. They can write their own grammar.

Craziness, but definitely a good kind of craziness. Despite wanting to feel that white-space sensitivity is just wrong, I suspect this will help DWIMery. It’s going to take a lot of time to absorb all of this, though. Hopefully the corresponding Exegesis won’t be too far behind.

Next: iTunes
Previous: Night