On 2/3/06, Doug H <doug00 / gmail.com> wrote:
>
> Sky Yin wrote:
> > >
> > > Even if "end if" is no longer feasible to parse because of the if
> > > modifier there is still the possibility to have optional "end def" and
> > > "end class" instead of just "end". It could make finding the place
> > > where an end is missing much easier.
> > >
> > > Michal
> > >
> >
> > (0..10).each do |i|
> >   # Do something with i
> > end what?
>
> end do
>

I've always just done this:

def blah(var)
  if something
    case var
    when 'x'
      foo
    when 'y'
      bar
    end#case
  end#if
end#blah