From: WATANABE Hirofumi Date: 2007-02-23T11:13:56+09:00 Subject: Re: Ruby's "case" doesn't behave like a normal switch Hi, On Fri, Feb 23, 2007 at 10:55:06AM +0900, Guillaume Nargeot wrote: > The fact is that you don't want to rewrite the same code two times. > Of course, you would be able to right your code into a function, and then > just > write: > > case x > when "this" > func_this_that() > when "that" > func_this_that() > when "nothing" > # something different > end case x when "this", "that" func_this_that() when "nothing" # something different end -- eban