On Wed, Aug 19, 2009 at 5:29 PM, Alexandre Bergel
<alexandre@bergel.eu> wrote:
Dear List,
Consider the following method:
-=-=-=-=-=-=-=-=-=-=-=-=
AClass>>aMethod
� � � �^ self compute
� � � � � � � �ifTrue: [ #aSelector ]
� � � � � � � �ifFalse: [ false ]
-=-=-=-=-=-=-=-=-=-=-=-=
I read somewhere that having a method that may return different type
of values is not of a good style.
It would be worst if they are not only different type but also not polymorphic
�
I first through it was in Kent's
book, but I cannot find it.
Is there a book that talk about this coding style?
Cheers,
Alexandre
--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel �http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
_______________________________________________
Pharo-project mailing list
Pharo-project@lists.gforge.inria.fr
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project