lib/memdump/memory_dump.rb
# Validate that all reference entries have a matching dump entry
#
# @raise [RuntimeError] if references have been found
Validate that all reference entries have a matching dump entry
Validate that all reference entries have a matching dump entry
def validate_references
            addresses = self.addresses.to_set
            each_record do |r|
                common = addresses & r['references']
                if common.size != r['references'].size
                    missing = r['references'] - common
                    raise "#{r} references #{missing.to_a.sort.join(", ")} which do not exist"
                end
            end
            nil
        end
def validate_references addresses = self . addresses . to_set each_record do | r | common = addresses & r [ 'references' ] if common . size != r [ 'references' ] . size missing = r [ 'references' ] - common raise "#{r} references #{missing.to_a.sort.join(", ")} which do not exist" end end nil end
Validate that all reference entries have a matching dump entry
Validate that all reference entries have a matching dump entry
[RuntimeError] if references have been found
[ RuntimeError ] if references have been found