Wolverian wrote:
> On Thu, Jul 07, 2005 at 05:58:53PM -0700, Larry Wall wrote:
>>    $fh.pos = $fh.pos + 10`lines
> I'm sorry if this has been discussed, but is the ` going to be in
> Perl 6? I like it. :) 
I was hoping it was going to be in the standard library, but non-core.
Using it for manipulating .pos, OTOH, would seem to make it core, which
I suppose is probably worth it.

> How does it work, though?
>     sub *infix:<`> (Num $amount, Unit $class) { $class.new($amount) }
> Or so?
> Now I'm tempted to make it a generic infix .new.
>     (args)`Class;

The problem with it is that somehow we have to get 5`m / 30`s to work,
even though m is an operator, which AFAIK means it needs to be a macro,
or the moral equivalent (is parsed).

Also, having every unit be a like-named class would very much crowd the
root of the namespace.

        -=- James Mastros

Reply via email to