Reduce memory usage by using symbols instead of strings for values.
Pass in use_symbols: true to options.
Note: I made an attempt to use Frozen Strings instead of Symbols, but in Ruby 2.3 these don't have the desired behavior. Frozen Strings created from string literals all map to the same instance/memory, but freezing an existing string just makes it immutable, without using the same global instance for that value.
Reduce memory usage by using symbols instead of strings for values.
Pass in
use_symbols: true
to options.Note: I made an attempt to use Frozen Strings instead of Symbols, but in Ruby 2.3 these don't have the desired behavior. Frozen Strings created from string literals all map to the same instance/memory, but freezing an existing string just makes it immutable, without using the same global instance for that value.
See: https://wyeworks.com/blog/2015/12/1/immutable-strings-in-ruby-2-dot-3