From: HarryO Date: 2001-12-31T15:01:35+09:00 Subject: [ruby-talk:29815] Re: Proc.class vs yield On Mon, 31 Dec 2001 16:19:48 +1100, Michael Lucas-Smith wrote: > The reason I'm bringing this up is because having a criteria block of > code and a failure block of code si very common in Smalltalk I wonder whether your failure block could be replaced by the throwing and catching of an exception? I realise, of course, that the standard containers don't tend to throw exceptions in this case. However, if you would like this behaviour, you might be able to either derive your own classes from them, or use Ruby's dynamic facilities to modify the behaviour of the containers themselves. Just a thought ... and someone else who knows how things work in ST may be able to clean it up to make it more palatable.