class Prism::IfNode

Parent:
Prism::Node

Represents the use of the ‘if` keyword, either in the block form or the modifier form, or a ternary expression.

bar if foo
^^^^^^^^^^

if foo then bar end
^^^^^^^^^^^^^^^^^^^

foo ? bar : baz
^^^^^^^^^^^^^^^

Ruby Core © 1993–2024 Yukihiro Matsumoto
Licensed under the Ruby License.
Ruby Standard Library © contributors
Licensed under their own licenses.