From: schneik@... Date: 2000-04-20T11:12:24-05:00 Subject: [ruby-talk:02534] Re: 'in' vs. 'into' Matz writes: # In message "[ruby-talk:02495] Re: 'in' vs. 'into'" # on 00/04/17, Andrew Hunt writes: # | # | ># rescue MyException into myVar # | ># # | >I agree. # | # |I like "into" as well, for what it's worth. # # Hmm, I've not decided yet. Here's the list of options: # # * rescue IOError in var # # Current parser accepts this syntax. No new reserved word # introduced. # # * rescue IOError into var # # More descriptive than 'in'. Introducing new reserved word, which # raise backward compatibility problem. For the time being, I vote for this one, although I think Dave's first suggestion might be a good choice (but I haven't had time to think about it). # * rescue IOError => var # # No reserved word introduced. Symbols may ambiguous. # # * exception # # This option introcudes new global function `exception' which # returns the $! value. No reserved word introduced. I think this # simple way. What happens if you have recoverable exceptions in exception handlers spread across multiple modules written by different people? Would you be able to rely on "$!"? (Would the very first thing that you would need to do is make a local copy of "$!"?) # * Exception::last # # This may more descriptive than mere `exception'. But I feel it's # too long to type in. You know I'm lazy. Notice `ruby' is 2 # letter shorter than `python'? Conrad Schneiker (This note is unofficial and subject to improvement without notice.)