syntax change for 1.9?

Discussion in 'Ruby' started by Roger Pack, Jun 17, 2008.

  1. Roger Pack

    Roger Pack Guest

    case 3
    when true && a = 3 rescue nil : false
    end


    this code errs in 1.9 and succeeds in 1.8.6
    Was this deliberate?
    [please ignore the lameness of the code--it was just a simplified
    example].
    Thanks!
    -R
    --
    Posted via http://www.ruby-forum.com/.
     
    Roger Pack, Jun 17, 2008
    #1
    1. Advertising

  2. Hi,

    At Tue, 17 Jun 2008 14:00:39 +0900,
    Roger Pack wrote in [ruby-talk:305381]:
    > case 3
    > when true && a = 3 rescue nil : false
    > end


    Using a colon instead of `then' wasn't an official feature.

    --
    Nobu Nakada
     
    Nobuyoshi Nakada, Jun 17, 2008
    #2
    1. Advertising

  3. Roger Pack

    Roger Pack Guest

    >> when true && a = 3 rescue nil : false
    >
    > Using a colon instead of `then' wasn't an official feature.


    Thanks!
    =R
    --
    Posted via http://www.ruby-forum.com/.
     
    Roger Pack, Jun 17, 2008
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. gabriele renzi
    Replies:
    2
    Views:
    221
    gabriele renzi
    Dec 31, 2005
  2. Ken Bloom
    Replies:
    3
    Views:
    224
  3. Good Night Moon
    Replies:
    9
    Views:
    292
    Rick DeNatale
    Jul 25, 2007
  4. Jacob Grover
    Replies:
    5
    Views:
    326
    Jacob Grover
    Jul 18, 2008
  5. Mark Richards
    Replies:
    3
    Views:
    324
    Tad McClellan
    Nov 18, 2007
Loading...

Share This Page