http://www.perlmonks.org?node_id=902613


in reply to Re: A couple questions on Moose::MOP::Class
in thread A couple questions on Moose::MOP::Class

... since Perl has no real way to tell the difference between a method and a function...

Maybe yours doesn't, but I have a patched version of Perl 5.13 right here which does!

  • Comment on Re^2: A couple questions on Moose::MOP::Class

Replies are listed 'Best First'.
Re^3: A couple questions on Moose::MOP::Class
by John M. Dlugosz (Monsignor) on May 03, 2011 at 04:32 UTC
    How does it tell? Any sub created in the Package looks the same... how does it know you intend to call it using the arrow-notation dispatch and expect the class or instance as the first parameter?

      I added a method keyword.

        That is cheating :)

        -stvn