Package org.armedbear.lisp
Class LispThread
java.lang.Object
org.armedbear.lisp.LispObject
org.armedbear.lisp.LispThread
- All Implemented Interfaces:
Inspectable
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Primitive
static final Primitive
Stack holding bindings for evaluated functionsstatic final Primitive
static final Primitive
static Symbol
static final Primitive
static final Primitive
static final Primitive
static final SpecialOperator
static Symbol
-
Method Summary
Modifier and TypeMethodDescriptionfinal LispObject[]
accumulateValues
(LispObject result, LispObject[] oldValues) Used by the JVM compiler for MULTIPLE-VALUE-CALL.backtrace
(int limit) final SpecialBinding
bindSpecial
(Symbol name, LispObject value) final SpecialBinding
classOf()
final void
static final LispThread
execute
(LispObject function) execute
(LispObject function, LispObject arg) execute
(LispObject function, LispObject[] args) execute
(LispObject function, LispObject first, LispObject second) execute
(LispObject function, LispObject first, LispObject second, LispObject third) execute
(LispObject function, LispObject first, LispObject second, LispObject third, LispObject fourth) execute
(LispObject function, LispObject first, LispObject second, LispObject third, LispObject fourth, LispObject fifth) execute
(LispObject function, LispObject first, LispObject second, LispObject third, LispObject fourth, LispObject fifth, LispObject sixth) execute
(LispObject function, LispObject first, LispObject second, LispObject third, LispObject fourth, LispObject fifth, LispObject sixth, LispObject seventh) execute
(LispObject function, LispObject first, LispObject second, LispObject third, LispObject fourth, LispObject fifth, LispObject sixth, LispObject seventh, LispObject eighth) getParts()
Implementing the getParts() protocol will allow INSPECT to return information about the substructure of a descendent of LispObject.final SpecialBinding
getSpecialBinding
(Symbol name) final LispObject[]
final LispObject[]
getValues
(LispObject result, int count) void
final boolean
final LispObject
lookupSpecial
(Symbol name) Looks up the value of a special binding in the context of the given thread.final SpecialBindingsMark
Marks the state of the special bindings, for later rewinding by resetSpecialBindings().final LispObject
nothing()
void
void
void
printBacktrace
(int limit) void
pushCatchTag
(LispObject tag) final LispObject
pushSpecial
(Symbol name, LispObject thing) final void
pushStackFrame
(JavaStackFrame frame) final void
rebindSpecial
(Symbol name, LispObject value) protected static void
Frees up an index previously assigned to a symbol for re-assignment to another symbol.final void
Restores the state of the special bindings to what was captured in the marker 'mark' by a call to markSpecialBindings().void
final LispObject
safeSymbolValue
(Symbol name) final Environment
setEnv
(Environment env) final LispObject
setSpecialVariable
(Symbol name, LispObject value) final LispObject
final LispObject
setValues
(LispObject value1) final LispObject
setValues
(LispObject[] values) final LispObject
setValues
(LispObject value1, LispObject value2) final LispObject
setValues
(LispObject value1, LispObject value2, LispObject value3) final LispObject
setValues
(LispObject value1, LispObject value2, LispObject value3, LispObject value4) void
throwToTag
(LispObject tag, LispObject result) typeOf()
typep
(LispObject typeSpecifier) final LispObject
value
(LispObject obj) Force a single value, for situations where multiple values should be ignored.static boolean
Methods inherited from class org.armedbear.lisp.LispObject
ABS, add, add, aref, AREF, AREF, aref_long, aset, aset, aset, ash, ash, atom, ATOM, caddr, cadr, car, cddr, cdr, CHAR, characterp, CHARACTERP, chars, COMPLEXP, constantp, CONSTANTP, copyToArray, decr, DENOMINATOR, dispatch, divideBy, doubleValue, elt, endp, ENDP, EQ, eql, eql, eql, EQL, equal, equal, EQUAL, equalp, equalp, evenp, EVENP, execute, execute, execute, floatp, FLOATP, floatValue, getBooleanValue, getCallCount, getDescription, getDocumentation, getFixnumSlotValue, getHotCount, getInstance, getPropertyList, getSlotValue, getSlotValue_0, getSlotValue_1, getSlotValue_2, getSlotValue_3, getSlotValueAsBoolean, getStringChars, getStringValue, getSymbolFunction, getSymbolFunctionOrDie, getSymbolSetfFunction, getSymbolSetfFunctionOrDie, getSymbolValue, incr, incrementCallCount, incrementHotCount, integerp, INTEGERP, intValue, IS_E, IS_GE, IS_GT, IS_LE, IS_LT, IS_NE, isEqualTo, isEqualTo, isGreaterThan, isGreaterThan, isGreaterThanOrEqualTo, isGreaterThanOrEqualTo, isLessThan, isLessThan, isLessThanOrEqualTo, isLessThanOrEqualTo, isNotEqualTo, isNotEqualTo, isSpecialOperator, isSpecialVariable, javaInstance, javaInstance, LDB, length, LENGTH, listp, LISTP, lockableInstance, LOGAND, LOGAND, LOGIOR, LOGIOR, LOGNOT, LOGXOR, LOGXOR, longValue, minusp, MINUSP, MOD, MOD, multiplyBy, multiplyBy, negate, noFillPointer, NOT, nreverse, NTH, NTH, nthcdr, numberp, NUMBERP, NUMERATOR, oddp, ODDP, plusp, PLUSP, princToString, psxhash, psxhash, push, rationalp, RATIONALP, realp, REALP, resolve, reverse, RPLACA, RPLACD, SCHAR, setCallCount, setCar, setCdr, setDocumentation, setHotCount, setPropertyList, setSlotValue, setSlotValue, setSlotValue_0, setSlotValue_1, setSlotValue_2, setSlotValue_3, SIMPLE_STRING_P, SLOT_VALUE, STRING, stringp, STRINGP, subtract, subtract, SVREF, svset, sxhash, SYMBOLP, truncate, unreadableString, unreadableString, VECTOR_PUSH_EXTEND, VECTOR_PUSH_EXTEND, vectorp, VECTORP, vectorPushExtend, zerop, ZEROP
-
Field Details
-
_values
-
envStack
Stack holding bindings for evaluated functions -
NATIVE_THREADS
-
VIRTUAL_THREADS
-
CURRENT_THREAD
-
BACKTRACE
-
FRAME_TO_STRING
-
FRAME_TO_LIST
-
SYNCHRONIZED_ON
-
OBJECT_WAIT
-
OBJECT_NOTIFY
-
OBJECT_NOTIFY_ALL
-
-
Method Details
-
currentThread
-
getParts
Description copied from class:LispObject
Implementing the getParts() protocol will allow INSPECT to return information about the substructure of a descendent of LispObject. The protocol is to return a List of Cons pairs, where the car of each pair contains a decriptive string, and the cdr returns a subobject for inspection.- Specified by:
getParts
in interfaceInspectable
- Overrides:
getParts
in classLispObject
-
virtualThreadingAvailable
public static boolean virtualThreadingAvailable() -
getJavaStackTrace
-
typeOf
- Overrides:
typeOf
in classLispObject
-
classOf
- Overrides:
classOf
in classLispObject
-
typep
- Overrides:
typep
in classLispObject
-
isDestroyed
public final boolean isDestroyed() -
getValues
-
getValues
-
accumulateValues
Used by the JVM compiler for MULTIPLE-VALUE-CALL. -
setValues
-
setValues
-
setValues
-
setValues
-
setValues
public final LispObject setValues(LispObject value1, LispObject value2, LispObject value3, LispObject value4) -
setValues
-
clearValues
public final void clearValues() -
nothing
-
value
Force a single value, for situations where multiple values should be ignored. -
markSpecialBindings
Marks the state of the special bindings, for later rewinding by resetSpecialBindings(). -
resetSpecialBindings
Restores the state of the special bindings to what was captured in the marker 'mark' by a call to markSpecialBindings(). -
releaseSpecialIndex
Frees up an index previously assigned to a symbol for re-assignment to another symbol. Returns without effect if the symbol has the default UNASSIGNED_SPECIAL_INDEX special index. -
bindSpecial
-
bindSpecialToCurrentValue
-
lookupSpecial
Looks up the value of a special binding in the context of the given thread. In order to find the value of a special variable (in general), useSymbol.symbolValue()
.- Parameters:
name
- The name of the special variable, normally a symbol- Returns:
- The inner most binding of the special, or null if unbound
- See Also:
-
getSpecialBinding
-
setSpecialVariable
-
pushSpecial
-
safeSymbolValue
-
rebindSpecial
-
pushCatchTag
-
popCatchTag
public void popCatchTag() -
throwToTag
-
pushStackFrame
-
setEnv
-
resetStack
public void resetStack() -
execute
- Overrides:
execute
in classLispObject
-
execute
- Overrides:
execute
in classLispObject
-
execute
- Overrides:
execute
in classLispObject
-
execute
public LispObject execute(LispObject function, LispObject first, LispObject second, LispObject third) - Overrides:
execute
in classLispObject
-
execute
public LispObject execute(LispObject function, LispObject first, LispObject second, LispObject third, LispObject fourth) - Overrides:
execute
in classLispObject
-
execute
public LispObject execute(LispObject function, LispObject first, LispObject second, LispObject third, LispObject fourth, LispObject fifth) - Overrides:
execute
in classLispObject
-
execute
public LispObject execute(LispObject function, LispObject first, LispObject second, LispObject third, LispObject fourth, LispObject fifth, LispObject sixth) - Overrides:
execute
in classLispObject
-
execute
public LispObject execute(LispObject function, LispObject first, LispObject second, LispObject third, LispObject fourth, LispObject fifth, LispObject sixth, LispObject seventh) - Overrides:
execute
in classLispObject
-
execute
public LispObject execute(LispObject function, LispObject first, LispObject second, LispObject third, LispObject fourth, LispObject fifth, LispObject sixth, LispObject seventh, LispObject eighth) -
execute
-
printBacktrace
public void printBacktrace() -
printBacktrace
public void printBacktrace(int limit) -
backtrace
-
incrementCallCounts
public void incrementCallCounts() -
printObject
- Overrides:
printObject
in classLispObject
-