Module: SystemRDL::Evaluator::ArrayInstance

Included in:
BlockInstance, RegInstance
Defined in:
lib/systemrdl/evaluator/array_component.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#array_infoObject

Returns the value of attribute array_info.



47
48
49
# File 'lib/systemrdl/evaluator/array_component.rb', line 47

def array_info
  @array_info
end

Instance Method Details

#array?Boolean

Returns:



49
50
51
# File 'lib/systemrdl/evaluator/array_component.rb', line 49

def array?
  !array_info.nil?
end

#array_indicesObject



53
54
55
# File 'lib/systemrdl/evaluator/array_component.rb', line 53

def array_indices
  array_info&.indices
end

#array_sizesObject



57
58
59
# File 'lib/systemrdl/evaluator/array_component.rb', line 57

def array_sizes
  array_info&.sizes
end

#first_element?Boolean

Returns:



61
62
63
# File 'lib/systemrdl/evaluator/array_component.rb', line 61

def first_element?
  !array? || array_info.first
end

#last_element?Boolean

Returns:



65
66
67
# File 'lib/systemrdl/evaluator/array_component.rb', line 65

def last_element?
  !array? || array_info.last
end