Skip to content
On this page

Maintenance Ruby 3.4 gets fixes, but no new features. Switch to Ruby 4.0 →

class · Ruby 3.4

Prism::CallNode

< Prism::Node 27 instance methods 2 class methods

Represents a method call, in all of the various forms that can take.

foo
^^^

foo()
^^^^^

+foo
^^^^

foo + bar
^^^^^^^^^

foo.bar
^^^^^^^

foo&.bar
^^^^^^^^

Class methods 2

Instance methods 27

Attributes
Read

Represents the arguments to the method call. These can be any [non-void expressions](github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).

foo(bar)
    ^^^
Read

Represents the block that is being passed to the method.

foo { |a| a }
    ^^^^^^^^^
Read

Represents the name of the method being called.

foo.bar # name `:foo`
^^^
Read

The object that the method is being called on. This can be either nil or any [non-void expression](github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).

foo.bar
^^^

+foo
 ^^^

foo + bar
^^^