Class: RLSL::Prism::IR::ForLoop
- Defined in:
- lib/rlsl/prism/ir/control_flow.rb
Instance Attribute Summary collapse
-
#body ⇒ Object
readonly
Returns the value of attribute body.
-
#range_end ⇒ Object
readonly
Returns the value of attribute range_end.
-
#range_start ⇒ Object
readonly
Returns the value of attribute range_start.
-
#variable ⇒ Object
readonly
Returns the value of attribute variable.
Attributes inherited from Node
Instance Method Summary collapse
-
#initialize(variable, range_start, range_end, body) ⇒ ForLoop
constructor
A new instance of ForLoop.
Methods inherited from Node
Constructor Details
#initialize(variable, range_start, range_end, body) ⇒ ForLoop
Returns a new instance of ForLoop.
50 51 52 53 54 55 56 57 |
# File 'lib/rlsl/prism/ir/control_flow.rb', line 50 def initialize(variable, range_start, range_end, body) super() @variable = variable @range_start = range_start @range_end = range_end @body = body @type = nil end |
Instance Attribute Details
#body ⇒ Object (readonly)
Returns the value of attribute body.
46 47 48 |
# File 'lib/rlsl/prism/ir/control_flow.rb', line 46 def body @body end |
#range_end ⇒ Object (readonly)
Returns the value of attribute range_end.
46 47 48 |
# File 'lib/rlsl/prism/ir/control_flow.rb', line 46 def range_end @range_end end |
#range_start ⇒ Object (readonly)
Returns the value of attribute range_start.
46 47 48 |
# File 'lib/rlsl/prism/ir/control_flow.rb', line 46 def range_start @range_start end |
#variable ⇒ Object (readonly)
Returns the value of attribute variable.
46 47 48 |
# File 'lib/rlsl/prism/ir/control_flow.rb', line 46 def variable @variable end |