in reply to Inheritance via class::derived_method Question
So, the inheritance mechanism does not work for this?
The 'inheritance mechanism' is the -> operator, which is used in
Horse->speak();
but entirely absent (and so cannot work) in
Horse::speak("Horse");
which is an invocation of the Horse package's speak subroutine, which is undefined in the OPed example.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Inheritance via class::derived_method Question
by ikegami (Patriarch) on Nov 18, 2010 at 22:55 UTC | |
by How09 (Novice) on Nov 20, 2010 at 06:26 UTC | |
by ikegami (Patriarch) on Nov 22, 2010 at 17:31 UTC |