module Util
Public Class Methods
concatenate(_h, _start, _length = 1)
click to toggle source
# File lib/elfcat/util.rb, line 22 def self.concatenate _h, _start, _length = 1 start = _start length = _length result = 0 loop do result |= (_h[start] << ((length - 1) * 8)) length -= 1 break if length == 0 start += 1 end return {address: _start, length: _length, data: result} end