Class: YTLJit::AsmType::Array
- Inherits:
-
TypeCommon
- Object
- TypeCommon
- YTLJit::AsmType::Array
- Defined in:
- lib/ytljit/type.rb
Instance Attribute Summary
Attributes inherited from TypeCommon
Instance Method Summary collapse
- #[](n = 0, offset = 0) ⇒ Object
- #alignment ⇒ Object
-
#initialize(type, size) ⇒ Array
constructor
A new instance of Array.
- #size ⇒ Object
Constructor Details
#initialize(type, size) ⇒ Array
Returns a new instance of Array.
68 69 70 71 |
# File 'lib/ytljit/type.rb', line 68 def initialize(type, size) @type = type @size = size end |
Instance Method Details
#[](n = 0, offset = 0) ⇒ Object
81 82 83 |
# File 'lib/ytljit/type.rb', line 81 def [](n = 0, offset = 0) PointedData.new(@type, n, offset) end |
#alignment ⇒ Object
77 78 79 |
# File 'lib/ytljit/type.rb', line 77 def alignment @type.alignment end |
#size ⇒ Object
73 74 75 |
# File 'lib/ytljit/type.rb', line 73 def size @size * @type.size end |