Method: Onceler::Recordable#__data
- Defined in:
- lib/onceler/recordable.rb
#__data(inherit = false) ⇒ Object
81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 |
# File 'lib/onceler/recordable.rb', line 81 def __data(inherit = false) @__data ||= {} @__data[inherit] ||= begin @__comparison_cache = {} data = [__ivars(inherit), __retvals(inherit)] begin data = Marshal.dump(data) rescue TypeError data.each do |hash| hash.each do |key, val| find_dump_error(key, val) end end raise # find_dump_error should have re-raised, but just in case... ensure __visited_dump_vars.clear end @__comparison_cache = nil data end end |