Module: Struct::Default_Value::SubclassInstanceMethods

Defined in:
lib/struct/default_value/subclassinstancemethods.rb

Instance Method Summary collapse

Instance Method Details

#initialize(*values) ⇒ Object


7
8
9
10
11
12
# File 'lib/struct/default_value/subclassinstancemethods.rb', line 7

def initialize(*values)
  super
  values.length.upto(length - 1) do |idx|
    self[idx] = self.class.__send__ :_default_value_for_index, self, idx
  end
end