in reply to Re^2: Inherit only few methods from a parent class
in thread Inherit only few methods from a parent class

If the "risky" methods are used in the parent class, the inheriting child class may die unexpectedly
I agree with everything above, except the word unexpectedly. Yes, it will die. On purpose. Because the OP does not want those methods be callable. And if the Parent class calls those subs as methods, it's calling them on objects of type Child. Which the OP doesn't want. Hence death.
  • Comment on Re^3: Inherit only few methods from a parent class

Replies are listed 'Best First'.
Re^4: Inherit only few methods from a parent class
by afoken (Chancellor) on Jul 14, 2009 at 21:48 UTC

    Let's say "dies unexpectedly for the OP". I had and still have the impression that the OP hasn't completely understood inheritance yet.

    If the OP would show us some code, and explain why (s)he thinks that some methods in the parent class are risky, we could do much more than just guessing.

    Alexander

    --
    Today I will gladly share my knowledge and experience, for there are no sweeter words than "I told you so". ;-)