So I noticed that hash with indifferent access is not indifferent to 
integers as keys.

Currently this doesn't work.

hash = HashWithIndifferentAccess.new({"1" =>3})
hash[1] # => 3

The specific use case for me was passing around ids from the browser which 
was necessary because the form was using dynamic fields generated from 
database records, like a form with questions stored in the database.
We could make hashes with indifferent access truly indifferent which would 
help this particular use case. I'm not sure what type of existing code this 
would break, but I'm interested to learn what issues there would be with 
this feature. What do y'all think of this idea?

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Core" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/rubyonrails-core.
For more options, visit https://groups.google.com/d/optout.

Reply via email to