It syntax checks ok for me. I pasted it into one of my files and it
is fine. Ruby 1.8.7. Are you sure it is not a problem in the
surrounding code somewhere. Is it ok if you replace it with a simple
line of code, or initially comment it out? Alternatively perhaps
there is an non-printing character on that line that is confusing the
parser. Try re-typing it completely.
I forgot to mention I write in Ruby 1.9.2… but whatever
I should have the same error running irb …
I replaced this line with a do block and it’s running fine … Did
Einstein said : “Ruby don’t play dice” ?
I forgot to mention I write in Ruby 1.9.2… but whatever
I should have the same error running irb …
I replaced this line with a do block and it’s running fine … Did
Einstein said : “Ruby don’t play dice” ?
Ah, but God did give electrons a bit of freewill. Ruby interpreters may
take
similar libertes
Jeffrey
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.