One thing that is incredibly frustrating about certain classes of changes is that I have to implement 90% of it to find out if it's worth it
-
-
One thing that I find very interesting though is that this means that `attributes[:foo].value` has a signficiant performance difference from `attributes.fetch_value(:foo)` even though the definition is just https://github.com/rails/rails/blob/daf77db65d9d5e295ee3ba86605988875cb834e4/activerecord/lib/active_record/attribute_set.rb#L46-L48 … in Ruby
-
The reason for the difference is that `#[]` has to return a Ruby object, which Ruby will try to garbage collect -- even though I gave it a null free function, and the memory involved will outlive when Ruby thinks it does. Just adds needless GC pressure
- 2 more replies
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.