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 TypeMethodDescriptionvoid
Append the list of variables used in this operand to the input liststatic Array
void
get
(int i) Operand[]
getElts()
getSimplifiedOperand
(Map<Operand, Operand> valueMap, boolean force) boolean
Do 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).boolean
isBlank()
iterator()
retrieve
(ThreadContext context, IRubyObject self, StaticScope currScope, DynamicScope currDynScope, Object[] temp) retrieveArrayElts
(ThreadContext context, IRubyObject self, StaticScope currScope, DynamicScope currDynScope, Object[] temp) int
size()
toArray()
toString()
void
Methods inherited from class org.jruby.ir.operands.Operand
canCopyPropagate, getValue, isFalseyImmediate, isTruthyImmediate
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
Array
public Array() -
Array
-
-
Method Details
-
getOperandType
- Specified by:
getOperandType
in classOperand
-
isBlank
public boolean isBlank() -
size
public int size() -
get
-
toString
-
hasKnownValue
public boolean hasKnownValue()Description copied from class:Operand
Do 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:
hasKnownValue
in classOperand
- Returns:
- true if a known compile-time value.
-
getSimplifiedOperand
- Overrides:
getSimplifiedOperand
in classOperand
-
toArray
-
addUsedVariables
Append the list of variables used in this operand to the input list- Specified by:
addUsedVariables
in classOperand
-
cloneForInlining
- Specified by:
cloneForInlining
in 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
-