class YARP::OrNode
Experimental RBS support (using type sampling data from the type_fusion
project).
# sig/yarp/node.rbs class YARP::OrNode < YARP::Node def child_nodes: () -> Array[YARP::CallNode] end
^^^^^^^^^^^^^
left or right
Represents the use of the ‘||` operator or the `or` keyword.
def accept(visitor)
def accept(visitor) visitor.visit_or_node(self) end
def child_nodes
Experimental RBS support (using type sampling data from the type_fusion
project).
def child_nodes: () -> YARP::ConstantPathNode
This signature was generated using 1 sample from 1 application.
def child_nodes [left, right] end
def comment_targets
def comment_targets [left, right, operator_loc] end
def copy(**params)
def copy(**params) OrNode.new( params.fetch(:left) { left }, params.fetch(:right) { right }, params.fetch(:operator_loc) { operator_loc }, params.fetch(:location) { location }, ) end
def deconstruct_keys(keys)
def deconstruct_keys(keys) { left: left, right: right, operator_loc: operator_loc, location: location } end
def initialize(left, right, operator_loc, location)
def initialize(left, right, operator_loc, location) @left = left @right = right @operator_loc = operator_loc @location = location end
def inspect(inspector = NodeInspector.new)
def inspect(inspector = NodeInspector.new) inspector << inspector.header(self) inspector << "├── left:\n" inspector << inspector.child_node(left, "│ ") inspector << "├── right:\n" inspector << inspector.child_node(right, "│ ") inspector << "└── operator_loc: #{inspector.location(operator_loc)}\n" inspector.to_str end
def operator
def operator operator_loc.slice end