Ruby on Rails Monday, August 26, 2013

tamouse m. wrote in post #1119628:
> On Aug 26, 2013, at 2:42 PM, Love U Ruby <lists@ruby-forum.com> wrote:
>
>
> You have a string which represents a what a Hash looks like. Why not run
> it through eval and see what you get?
>
> my_hash = eval(new_str)

I was trying to avoid `eval`. I tried also the `yaml`. But no luck :(

--
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 unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/e783312f4f38da2b6ade8a29eb1b53e8%40ruby-forum.com.
For more options, visit https://groups.google.com/groups/opt_out.

No comments:

Post a Comment