Lazycoder

9Feb/050

calling a super method from an sub class instance

smart brother : Smartbrother.org – blog or scratchpad? ¬ͺ Blog Archive ¬ͺ Class inheritance, super invocation, and infinite loops.

Jon over at smartbrother.org notes some unusual behavior when calling a super classes method from a subclass instance. In essence, he creates an infinite loop. Well, that’s not exactly true it’s finite to the size of his stack. ;)

The lesson here is, be careful when calling a super classes method from a subclass.

Filed under: Tutorials Leave a comment