On 12 June 2012 14:27, Jeff Gray <[email protected]> wrote: > So, for fun I wrote a PlayingCard class with two instance variables, suit > and > value. > calling collect: [:eachCard | eachCard value] > on a collection of cards didn't work as I'd expected, but of course 'value' > is the method on Object that returns self. > > Easily fixed by renaming the 'value' variable to faceValue (and associated > accessors), but made me laugh... >
PlayingCard>>value will override Object>>value. Noting funny about that. -- Milan Mimica http://sparklet.sf.net
