Package org.jruby.ir.operands
Class Array
java.lang.Object
org.jruby.ir.operands.Operand
org.jruby.ir.operands.Array
-
Field Summary
Fields inherited from class org.jruby.ir.operands.Operand
EMPTY_ARRAY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidAppend the list of variables used in this operand to the input liststatic Arrayvoidget(int i) Operand[]getElts()getSimplifiedOperand(Map<Operand, Operand> valueMap, boolean force) booleanDo we know the value of this operand at compile-time? If we do then it may be possible to constant propagate (one case: We also know it is also an ImmutableLiteral).booleanisBlank()iterator()retrieve(ThreadContext context, IRubyObject self, StaticScope currScope, DynamicScope currDynScope, Object[] temp) retrieveArrayElts(ThreadContext context, IRubyObject self, StaticScope currScope, DynamicScope currDynScope, Object[] temp) intsize()toArray()toString()voidMethods inherited from class org.jruby.ir.operands.Operand
canCopyPropagate, getValue, isFalseyImmediate, isTruthyImmediateMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
Array
public Array() -
Array
-
-
Method Details
-
getOperandType
- Specified by:
getOperandTypein classOperand
-
isBlank
public boolean isBlank() -
size
public int size() -
get
-
toString
-
hasKnownValue
public boolean hasKnownValue()Description copied from class:OperandDo we know the value of this operand at compile-time? If we do then it may be possible to constant propagate (one case: We also know it is also an ImmutableLiteral).- Overrides:
hasKnownValuein classOperand- Returns:
- true if a known compile-time value.
-
getSimplifiedOperand
- Overrides:
getSimplifiedOperandin classOperand
-
toArray
-
addUsedVariables
Append the list of variables used in this operand to the input list- Specified by:
addUsedVariablesin classOperand
-
cloneForInlining
- Specified by:
cloneForInliningin classOperand
-
encode
-
decode
-
retrieveArrayElts
public IRubyObject[] retrieveArrayElts(ThreadContext context, IRubyObject self, StaticScope currScope, DynamicScope currDynScope, Object[] temp) -
retrieve
public Object retrieve(ThreadContext context, IRubyObject self, StaticScope currScope, DynamicScope currDynScope, Object[] temp) -
visit
-
getElts
-
iterator
-