From: Brian Mitchell Date: 2007-12-08T07:41:24+09:00 Subject: Re: Clarification of retry change On Dec 7, 2007 4:56 PM, Michal Suchanek wrote: > Hello > > When talking about the places where retry is allowed .. what does this > imply for retry inside if, case, and while? > > I do not really use retry nor am I familiar with the grammar trees you > keep talking about. Just want to remind that there are branching > constructs inside which the retry might make sense (when placed inside > a rescue). I'm not the authority in this case, but those should be working fine after this change. This mainly deals with any code run by calling a method inside the rescue. In these cases, you would have to use some sort of control mechanism to externalize the need to execute the retry [0]. Brian. [0]: Something might look like this.. more work but it works. I'm not sure many will have a case to need something like this. def retry? catch :retry do yield return false end true end def indirect_retry throw :retry end rescued = false begin p :begin raise rescue p :rescue ret = retry? do indirect_retry unless rescued end if ret rescued = true retry end ensure p :ensure end