Frederick Cheung wrote:
> On May 28, 11:44�am, Ale Ds <li...@ruby-forum.com> wrote:
> ...
> and has very low precedence, so ruby actually treats this as
>
> (user_params = (params[:user_param])) and
> (params[:user_param].to_hash)
>
> && on the other hand binds more tightly and would do what you expect.
>
> Fred
I will carefully use 'and' next time,
or maybe I will use only && :)
After your reply, I've found this
http://www.themomorohoax.com/2008/12/08/and-vs-amperand-in-ruby
Thank you very much !
Alessandro DS
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
No comments:
Post a Comment