[squeak-dev] Self new in arrowPrototype

Randal L. Schwartz merlyn at stonehenge.com
Fri Jun 3 14:44:08 UTC 2011


>>>>> "Rodney" == Rodney Polkinghorne <rodneyp at physics.uq.edu.au> writes:


Rodney> I think the "self new" should be "super new", reasoning as
Rodney> follows:

Lemme stop you right there (since you aren't in the #new method):

A simple rule of thumb is that you NEVER call "super XXX" from any
method other than "XXX".  Violate that, and you have code smell.

The point of super is to get at my superclass definition of the method
I'm currently in.  Not to go messing with the protocols in general.

-- 
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<merlyn at stonehenge.com> <URL:http://www.stonehenge.com/merlyn/>
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.posterous.com/ for Smalltalk discussion



More information about the Squeak-dev mailing list