Glenn Linderman wrote:
>
> > /Class->blah/ # ditto
>
> for the middle of the above example, what happens when
>
> package Class;
> package lass;
> package ass;
> package ss;
>
> /Class->blah/ then becomes pretty ambiguous.
Actually, I don't think so. The -> should simply act on \b\w+ before it,
like anywhere else in Perl:
$stuff = Class->blah;
So regardless of the packages imported "Class" would always be called.
One potential way to override this:
/{Class}->blah/
/C{lass}->blah/
/Cl{ass}->blah/
/Cla{ss}->blah/
This is consistent with the way ref variables work currently:
${r}->blah; # class method
${h}->{key}; # hash ref key
${a}->[0]; # array ref key
I'll add this to the RFC unless there are objections.
-Nate