Package org.jruby.ast
Class BlockPassNode
java.lang.Object
org.jruby.ast.Node
org.jruby.ast.BlockPassNode
Explicit block argument (on caller side):
foobar(1, 2, &foo)
foobar(1, 2, &lhs_which_returns_something_block/proc_like)
bodyNode is any expression which can return something which is ultimately
coercible to a proc.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate NodeUsed by the arg_blk_pass and new_call, new_fcall and new_super methods in ParserSupport to temporary save the args node.private final NodeFields inherited from class org.jruby.ast.Node
containsVariableAssignment, EMPTY_LIST, newline -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<T> Taccept(NodeVisitor<T> iVisitor) Accept for the visitor pattern.Gets the argsNode.Gets the bodyNode.voidsetArgsNode(Node argsNode) Sets the argsNode.Methods inherited from class org.jruby.ast.Node
containsVariableAssignment, createList, createList, createList, createList, executesOnce, findFirstChild, getFile, getLine, getNodeName, isNewline, isNil, needsDefinitionCheck, setLine, setNewline, toString, toString, toStringExtraInfo, toStringInternal, unsetNewline
-
Field Details
-
bodyNode
-
argsNode
Used by the arg_blk_pass and new_call, new_fcall and new_super methods in ParserSupport to temporary save the args node. This should not be used directly by compiler or interpreter.
-
-
Constructor Details
-
BlockPassNode
-
-
Method Details
-
getNodeType
- Specified by:
getNodeTypein classNode- Returns:
- the nodeId
-
accept
Accept for the visitor pattern. -
getBodyNode
Gets the bodyNode.- Returns:
- Returns a Node
-
getArgsNode
Gets the argsNode.- Returns:
- Returns a IListNode
-
setArgsNode
Sets the argsNode.- Parameters:
argsNode- The argsNode to set
-
childNodes
- Specified by:
childNodesin classNode
-