in reply to Re^3: Skipping the middle man & the SUPER gotcha
in thread Skipping the middle man & the SUPER gotcha

No, with the arrow notation, the extra class information just tells it where to start looking in the class hierarchy. It's only identical to a sub call if the method in question is actually found in the class you named.
  • Comment on Re^4: Skipping the middle man & the SUPER gotcha

Replies are listed 'Best First'.
Re^5: Skipping the middle man & the SUPER gotcha
by Thelonious (Scribe) on Apr 03, 2005 at 11:52 UTC
    Thanks for that. It's clear now, and suprising!

    It doesn't even matter what package the invocant is blessed into, or even if it's an arbitrary bare word.

    use strict; use warnings FATAL => 'all'; package Base; sub hello { print __PACKAGE__.": @{[ref $_[0] || $_[0]]}\n"; } package Kid; our @ISA = 'Base'; package Main; sub hello { print __PACKAGE__.": @{[ref $_[0] || $_[0]]}\n"; } package main; our @ISA = 'Main'; my $main = bless {}; $main->Kid::hello; # Base: main $main->hello; # Main: main __PACKAGE__->hello; # Main: main BareWord->Kid::hello; # Base: BareWord