Class: TRuby::IR::MethodCall
Overview
Method call
Instance Attribute Summary collapse
-
#arguments ⇒ Object
Returns the value of attribute arguments.
-
#block ⇒ Object
Returns the value of attribute block.
-
#method_name ⇒ Object
Returns the value of attribute method_name.
-
#receiver ⇒ Object
Returns the value of attribute receiver.
-
#type_args ⇒ Object
Returns the value of attribute type_args.
Attributes inherited from Node
#location, #metadata, #type_info
Instance Method Summary collapse
- #children ⇒ Object
-
#initialize(method_name:, receiver: nil, arguments: [], block: nil, type_args: [], **opts) ⇒ MethodCall
constructor
A new instance of MethodCall.
Methods inherited from Node
Constructor Details
#initialize(method_name:, receiver: nil, arguments: [], block: nil, type_args: [], **opts) ⇒ MethodCall
Returns a new instance of MethodCall.
196 197 198 199 200 201 202 203 |
# File 'lib/t_ruby/ir.rb', line 196 def initialize(method_name:, receiver: nil, arguments: [], block: nil, type_args: [], **opts) super(**opts) @receiver = receiver @method_name = method_name @arguments = arguments @block = block @type_args = type_args end |
Instance Attribute Details
#arguments ⇒ Object
Returns the value of attribute arguments.
194 195 196 |
# File 'lib/t_ruby/ir.rb', line 194 def arguments @arguments end |
#block ⇒ Object
Returns the value of attribute block.
194 195 196 |
# File 'lib/t_ruby/ir.rb', line 194 def block @block end |
#method_name ⇒ Object
Returns the value of attribute method_name.
194 195 196 |
# File 'lib/t_ruby/ir.rb', line 194 def method_name @method_name end |
#receiver ⇒ Object
Returns the value of attribute receiver.
194 195 196 |
# File 'lib/t_ruby/ir.rb', line 194 def receiver @receiver end |
#type_args ⇒ Object
Returns the value of attribute type_args.
194 195 196 |
# File 'lib/t_ruby/ir.rb', line 194 def type_args @type_args end |
Instance Method Details
#children ⇒ Object
205 206 207 |
# File 'lib/t_ruby/ir.rb', line 205 def children ([@receiver, @block] + @arguments).compact end |