Is [(FillInTheBlankMorph request: ' ) asNumber] on: Error do: []; necessary

Thomas Koenig tomkoenig at mindspring.com
Thu Dec 30 01:49:13 UTC 2004


I have a number of places in the code that look something like this:
[id _ (FillInTheBlankMorph request: 'Enter the id of the post you''d
like to jump to:' translated) asNumber ]
		 on: Error
		 do: [ self inform: 'That is not a valid number.'
translated.
		        ^ nil ].
Yet no mater what I key into the morph I don't trigger an error (don't
see the error  message.)  
Is there a good argument for keeping the error block?  If so can you
suggest an test condition that would trigger it.

I'm inclined to remove this code, because it appears to add only
complexity. 




More information about the Squeak-dev mailing list