A_Number

A_Number is an interface that specifies the number-specific operations that an AvailObject must implement. It's a sub-interface of A_BasicObject, the interface that defines the behavior that all AvailObjects are required to support.

Author

Mark van Gulik

Inheritors

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard

Extract a Kotlin Double from the receiver.

Link copied to clipboard

Extract a Java float from the receiver.

Link copied to clipboard

Extract a 32-bit signed Kotlin Int from the receiver.

Link copied to clipboard

Extract a 64-bit signed Java Long from the receiver.

Link copied to clipboard

Extract an unsigned nybble from the receiver. Return it as a Java Byte.

Link copied to clipboard

Extract a signed byte from the receiver.

Link copied to clipboard

Extract a signed short from the receiver.

Link copied to clipboard

Extract an unsigned byte from the receiver. Return it in a Java Short to avoid sign bit reinterpretation.

Link copied to clipboard

Extract an unsigned short from the receiver. Return it in a Kotlin Int to avoid sign bit reinterpretation.

Link copied to clipboard
abstract val isAbstract: Boolean

Dispatch to the descriptor.

Link copied to clipboard
abstract val isAtom: Boolean

Is the receiver an Avail atom?

Link copied to clipboard
abstract val isBoolean: Boolean

Is the receiver an Avail boolean?

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
abstract val isByteString: Boolean

Is the receiver an Avail byte string?

Link copied to clipboard
abstract val isByteTuple: Boolean

Is the receiver an Avail byte tuple?

Link copied to clipboard

Answer whether this value is a double-precision floating point number.

Link copied to clipboard

Is the receiver an Avail extended integer?

Link copied to clipboard
abstract val isFinite: Boolean

Dispatch to the descriptor.

Link copied to clipboard

Answer whether this value is a single-precision floating point number.

Link copied to clipboard
abstract val isFunction: Boolean

Is the receiver an Avail function?

Link copied to clipboard
abstract val isInstanceMeta: Boolean
Link copied to clipboard

Answer whether this value is an integer in the i32 range.

Link copied to clipboard
Link copied to clipboard

Dispatch to the descriptor.

Link copied to clipboard
abstract val isIntTuple: Boolean

Is the receiver an Avail IntTupleDescriptor? This is conservative, in that some object tuples may only contain ints but not be reported as being int tuples.

Link copied to clipboard
Link copied to clipboard

Answer whether this value is an integer in the i64 range.

Link copied to clipboard
abstract val isLongTuple: Boolean

Is the receiver an Avail LongTupleDescriptor? This is conservative, in that some object tuples may only contain longs but not be reported as being long tuples.

Link copied to clipboard
abstract val isMap: Boolean

Is the receiver an Avail map?

Link copied to clipboard
abstract val isMapType: Boolean

Dispatch to the descriptor.

Link copied to clipboard
open val isNil: Boolean

Test if the receiver is the nil value.

Link copied to clipboard

Answer whether this number is numerically equal to some finite integer.

Link copied to clipboard
abstract val isNybble: Boolean

Is the receiver an Avail nybble?

Link copied to clipboard
abstract val isPojo: Boolean
Link copied to clipboard
abstract val isPojoArrayType: Boolean
Link copied to clipboard
abstract val isPojoFusedType: Boolean
Link copied to clipboard
abstract val isPojoSelfType: Boolean
Link copied to clipboard
abstract val isPojoType: Boolean
Link copied to clipboard

Answer whether this integral infinity is positive.

Link copied to clipboard
abstract val isRawPojo: Boolean
Link copied to clipboard
Link copied to clipboard
abstract val isSetType: Boolean

Dispatch to the descriptor.

Link copied to clipboard

Answer whether this value is an integer in the range [-128..127].

Link copied to clipboard

Answer whether this value is an integer in the range [-32768..32767].

Link copied to clipboard
Link copied to clipboard
abstract val isString: Boolean

Is the receiver an Avail string?

Link copied to clipboard
abstract val isTokenType: Boolean
Link copied to clipboard
abstract val isTuple: Boolean

Is the receiver an Avail tuple?

Link copied to clipboard
abstract val isTupleType: Boolean

Dispatch to the descriptor.

Link copied to clipboard
abstract val isTwoByteString: Boolean

Is the receiver an Avail two-byte string?

Link copied to clipboard
abstract val isType: Boolean

Dispatch to the descriptor.

Link copied to clipboard
abstract val isUnsignedByte: Boolean

Is the receiver an Avail unsigned byte?

Link copied to clipboard

Answer whether this value is an integer in the range [0..65535].

Link copied to clipboard
Link copied to clipboard
open val notNil: Boolean

Test if the receiver is not the nil value.

Link copied to clipboard
Link copied to clipboard

Given an Avail integer, answer which power of two it is. 1->0, 2->1, 4->2, 8->3, etc. If the number is not a power of two, answer -1.

Functions

Link copied to clipboard
fun A_Number.addToDoubleCanDestroy(doubleObject: A_Number, canDestroy: Boolean): A_Number

Add the receiver to the given double, destroying one or the other if it's mutable and canDestroy is true. Because of the requirement that the argument be a double rather than an arbitrary A_Number, this is usually only used for double-dispatching.

Link copied to clipboard
fun A_Number.addToFloatCanDestroy(floatObject: A_Number, canDestroy: Boolean): A_Number

Add the receiver to the given float, destroying one or the other if it's mutable and canDestroy is true. Because of the requirement that the argument be a float rather than an arbitrary A_Number, this is usually only used for double-dispatching.

Link copied to clipboard

Add the receiver to the integral infinity with the given Sign, destroying one or the other if it's mutable and canDestroy is true. Because of the requirement that the argument be an integral infinity rather than an arbitrary A_Number, this is usually only used for double-dispatching.

Link copied to clipboard

Add the receiver to the given finite integer, destroying one or the other if it's mutable and canDestroy is true. Because of the requirement that the argument be an integer rather than an arbitrary A_Number, this is usually only used for double-dispatching.

Link copied to clipboard

Convert the receiver, which must be an integer, into a Java BigInteger.

Link copied to clipboard
abstract fun becomeIndirectionTo(anotherObject: A_BasicObject)

Turn the receiver into an indirection to the specified object.

Link copied to clipboard
fun A_Number.bitSet(bitPosition: Int, value: Boolean, canDestroy: Boolean): A_Number

Produce an integer like the receiver, but with the bit corresponding to 2^bitPosition either set or cleared, depending on value. The receiver may be recycled or destroyed if canDestroy is true.

Link copied to clipboard
fun A_Number.bitShift(shiftFactor: A_Number, canDestroy: Boolean): A_Number

Shift this integer left by the specified number of bits. If the shift amount is negative, perform a right shift instead (of the negation of the specified amount). In the case that the receiver is negative, shift in zeroes on the right or ones on the left.

Link copied to clipboard
fun A_Number.bitShiftLeftTruncatingToBits(shiftFactor: A_Number, truncationBits: A_Number, canDestroy: Boolean): A_Number

Shift the non-negative integer to the left by the specified number of bits, then truncate the representation to force bits above the specified position to be zeroed. The shift factor may be negative, indicating a right shift by the corresponding positive amount, in which case truncation will still happen.

Link copied to clipboard
fun A_Number.bitTest(bitPosition: Int): Boolean

Extract the bit with value 2^bitPosition from the integer, as a Boolean.

Link copied to clipboard
fun A_Number.bitwiseAnd(anInteger: A_Number, canDestroy: Boolean): A_Number

Compute the boolean and operation for the corresponding bits of the receiver and anInteger. Both values are signed 2's complement integers.

Link copied to clipboard
fun A_Number.bitwiseOr(anInteger: A_Number, canDestroy: Boolean): A_Number

Compute the boolean or operation for the corresponding bits of the receiver and anInteger. Both values are signed 2's complement integers.

Link copied to clipboard
fun A_Number.bitwiseXor(anInteger: A_Number, canDestroy: Boolean): A_Number

Compute the boolean exclusive-or operation for the corresponding bits of the receiver and anInteger. Both values are signed 2's complement integers.

Link copied to clipboard

Utility method for decomposing this object in the debugger.

Link copied to clipboard

Retrieve the object's {@linkplain AbstractDescriptor descriptor}.

Link copied to clipboard

Dispatcher helper function for routing messages to the descriptor.

Link copied to clipboard
fun A_Number.divideCanDestroy(aNumber: A_Number, canDestroy: Boolean): A_Number

Divide the receiver by the argument aNumber and answer the result.

Link copied to clipboard

Divide the double argument by the receiver, destroying one or the other if it's mutable and canDestroy is true. Because of the requirement that the argument be a double rather than an arbitrary A_Number, this is usually only used for double-dispatching.

Link copied to clipboard

Divide the float argument by the receiver, destroying one or the other if it's mutable and canDestroy is true. Because of the requirement that the argument be a float rather than an arbitrary A_Number, this is usually only used for double-dispatching.

Link copied to clipboard

Divide the infinity having the specified Sign by the receiver, destroying one or the other if it's mutable and canDestroy is true. Because of the requirement that the argument be an infinity rather than an arbitrary A_Number, this is usually only used for double-dispatching.

Link copied to clipboard

Divide the Avail integer argument by the receiver, destroying one or the other if it's mutable and canDestroy is true. Because of the requirement that the argument be an integer rather than an arbitrary A_Number, this is usually only used for double-dispatching.

Link copied to clipboard
abstract fun enumerationIncludesInstance(potentialInstance: AvailObject): Boolean
Link copied to clipboard
abstract fun equals(another: A_BasicObject): Boolean

Answer whether the receiver and the argument, both A_BasicObjects, are equal in value.

abstract operator override fun equals(other: Any?): Boolean

{@inheritDoc}

Link copied to clipboard
abstract fun equalsAnyTuple(aTuple: A_Tuple): Boolean

Answer whether the receiver, an object, and the argument, a tuple, are equal in value.

Link copied to clipboard
abstract fun equalsByteArrayTuple(aByteArrayTuple: A_Tuple): Boolean
Link copied to clipboard
abstract fun equalsByteBufferTuple(aByteBufferTuple: A_Tuple): Boolean
Link copied to clipboard
abstract fun equalsByteString(aByteString: A_String): Boolean

Answer whether the receiver, an object, and the argument, a byte string, are equal in value.

Link copied to clipboard
abstract fun equalsByteTuple(aByteTuple: A_Tuple): Boolean

Answer whether the receiver, an object, and the argument, a byte tuple, are equal in value.

Link copied to clipboard
abstract fun equalsCompiledCode(aCompiledCode: A_RawFunction): Boolean

Answer whether the arguments, an object and a compiled code, are equal.

Link copied to clipboard
abstract fun equalsCompiledCodeType(aCompiledCodeType: A_Type): Boolean
Link copied to clipboard
abstract fun equalsContinuation(aContinuation: A_Continuation): Boolean

Answer whether the receiver equals the argument.

Link copied to clipboard
abstract fun equalsContinuationType(aContinuationType: A_Type): Boolean

Answer whether the receiver equals the argument.

Link copied to clipboard
Link copied to clipboard
abstract fun equalsEnumerationType(anEnumerationType: A_BasicObject): Boolean
Link copied to clipboard

Determine whether the receiver is an enumeration with the given set of instances.

Link copied to clipboard
abstract fun equalsEqualityRawPojoFor(otherEqualityRawPojo: AvailObject, otherJavaObject: Any?): Boolean
Link copied to clipboard
abstract fun equalsFiberType(aFiberType: A_Type): Boolean

Answer whether the receiver, an object, and the argument, a fiber type, are equal in value.

Link copied to clipboard
Link copied to clipboard
abstract fun equalsFunction(aFunction: A_Function): Boolean

Answer whether the receiver, an object, and the argument, a function, are equal in value.

Link copied to clipboard
abstract fun equalsFunctionType(aFunctionType: A_Type): Boolean

Answer whether the receiver, an object, and the argument, a function type, are equal.

Link copied to clipboard

Answer whether the receiver is an infinity with the specified Sign.

Link copied to clipboard
abstract fun equalsInstanceTypeFor(anInstanceType: AvailObject): Boolean
Link copied to clipboard

Determine if the receiver is an Avail integer equivalent to the specified Kotlin Int. Note that a non-integer should simply answer false, not fail. This operation was placed in A_Number for organizational reasons, not type restriction.

Link copied to clipboard
Link copied to clipboard
abstract fun equalsIntegerIntervalTuple(anIntegerIntervalTuple: A_Tuple): Boolean
Link copied to clipboard
abstract fun equalsIntegerRangeType(anIntegerRangeType: A_Type): Boolean

Answer whether the receiver equals the argument.

Link copied to clipboard
abstract fun equalsIntTuple(anIntTuple: A_Tuple): Boolean
Link copied to clipboard
abstract fun equalsListNodeType(listNodeType: A_Type): Boolean

Answer whether this value equals the given list phrase type.

Link copied to clipboard
abstract fun equalsLiteralTokenType(aLiteralTokenType: A_Type): Boolean
Link copied to clipboard
abstract fun equalsLongTuple(aLongTuple: A_Tuple): Boolean
Link copied to clipboard
abstract fun equalsMap(aMap: A_Map): Boolean

Answer whether the receiver equals the argument.

Link copied to clipboard
abstract fun equalsMapType(aMapType: A_Type): Boolean

Answer whether the receiver equals the argument.

Link copied to clipboard
abstract fun equalsNybbleTuple(aNybbleTuple: A_Tuple): Boolean

Dispatch to the descriptor.

Link copied to clipboard
abstract fun equalsObject(anObject: AvailObject): Boolean

Dispatch to the descriptor.

Link copied to clipboard
abstract fun equalsObjectTuple(anObjectTuple: A_Tuple): Boolean

Dispatch to the descriptor.

Link copied to clipboard
abstract fun equalsObjectType(anObjectType: AvailObject): Boolean
Link copied to clipboard
abstract fun equalsPhraseType(aPhraseType: A_Type): Boolean
Link copied to clipboard
abstract fun equalsPojo(aPojo: AvailObject): Boolean
Link copied to clipboard
Link copied to clipboard
abstract fun equalsPojoField(field: AvailObject, receiver: AvailObject): Boolean
Link copied to clipboard
abstract fun equalsPojoType(aPojoType: AvailObject): Boolean
Link copied to clipboard
abstract fun equalsPrimitiveType(aPrimitiveType: A_Type): Boolean

Dispatch to the descriptor.

Link copied to clipboard
abstract fun equalsRawPojoFor(otherRawPojo: AvailObject, otherJavaObject: Any?): Boolean
Link copied to clipboard
abstract fun equalsRepeatedElementTuple(aRepeatedElementTuple: A_Tuple): Boolean
Link copied to clipboard
abstract fun equalsReverseTuple(aTuple: A_Tuple): Boolean
Link copied to clipboard
abstract fun equalsSetType(aSetType: A_Type): Boolean

Dispatch to the descriptor.

Link copied to clipboard
abstract fun equalsSmallIntegerIntervalTuple(aSmallIntegerIntervalTuple: A_Tuple): Boolean
Link copied to clipboard
abstract fun equalsToken(aToken: A_Token): Boolean
Link copied to clipboard
abstract fun equalsTokenType(aTokenType: A_Type): Boolean
Link copied to clipboard
abstract fun equalsTupleType(aTupleType: A_Type): Boolean

Dispatch to the descriptor.

Link copied to clipboard
abstract fun equalsTwentyOneBitString(aTwentyOneBitString: A_String): Boolean

Dispatch to the descriptor.

Link copied to clipboard
abstract fun equalsTwoByteString(aTwoByteString: A_String): Boolean

Dispatch to the descriptor.

Link copied to clipboard
abstract fun equalsVariableType(aVariableType: A_Type): Boolean

Answer whether the receiver equals the argument.

Link copied to clipboard
abstract fun fieldAt(field: A_Atom): AvailObject

Extract a field from an object.

Link copied to clipboard
abstract fun fieldAtIndex(index: Int): AvailObject

Extract a field from an object, using a one-based index into the field slots. This requires knowledge of the ObjectLayoutVariant, since the same field is at different indices in different variants.

Link copied to clipboard
abstract fun fieldAtOrNull(field: A_Atom): AvailObject?

Extract a field from an object, or answer null if it's not present.

Link copied to clipboard
abstract fun fieldAtPuttingCanDestroy(field: A_Atom, value: A_BasicObject, canDestroy: Boolean): A_BasicObject

Add or replace a field of an object.

Link copied to clipboard
abstract fun fieldMap(): A_Map

Dispatch to the descriptor.

Link copied to clipboard
abstract fun fieldTuple(): A_Tuple
Link copied to clipboard
abstract fun fieldTypeAt(field: A_Atom): A_Type

Extract a field type from an object type.

Link copied to clipboard
abstract fun fieldTypeAtIndex(index: Int): A_Type

Extract a field type from an object type, using the given field index, which is specific to an ObjectLayoutVariant.

Link copied to clipboard
abstract fun fieldTypeAtOrNull(field: A_Atom): A_Type?

Extract a field type from an object type, or null if it's not present.

Link copied to clipboard

Answer whether the receiver is numerically greater than or equivalent to the argument.

Link copied to clipboard

Answer whether the receiver is numerically greater than the argument.

Link copied to clipboard
abstract fun hash(): Int

Compute the 32-bit hash of the receiver.

Link copied to clipboard
abstract override fun hashCode(): Int
Link copied to clipboard
abstract fun hashOrZero(): Int

Dispatch to the descriptor.

Link copied to clipboard
open fun <T : A_BasicObject> ifNil(action: () -> T): T

If the receiver isNil, evaluate the action. Answer either the non-nil receiver, or the result of the action.

Link copied to clipboard
open fun <T : A_BasicObject> ifNotNil(action: (T) -> Unit)

If the receiver is notNil, evaluate the action with it.

Link copied to clipboard
abstract fun integerSlotsCount(): Int

Answer the number of integer slots. All variable integer slots occur following the last fixed integer slot.

Link copied to clipboard
abstract fun isInstanceOf(aType: A_Type): Boolean

Dispatch to the descriptor.

Link copied to clipboard
abstract fun isInstanceOfKind(aType: A_Type): Boolean

Dispatch to the descriptor.

Link copied to clipboard
abstract fun javaAncestors(): AvailObject
Link copied to clipboard
abstract fun javaClass(): A_BasicObject
Link copied to clipboard
abstract fun <T : Any> javaObject(): T?
Link copied to clipboard
abstract fun <T : Any> javaObjectNotNull(): T
Link copied to clipboard
abstract fun kind(): A_Type

Dispatch to the descriptor.

Link copied to clipboard

Answer whether the receiver is numerically less than or equivalent to the argument.

Link copied to clipboard

Answer whether the receiver is numerically less than the argument.

Link copied to clipboard
abstract fun <T> lock(body: () -> T): T

Lock the fiber during evaluation of the Supplier, and return the produced value.

Link copied to clipboard
abstract fun makeImmutable(): AvailObject

Dispatch to the descriptor.

Link copied to clipboard
abstract fun makeImmutableInternal(queueToProcess: MutableList<AvailObject>, fixups: MutableList<() -> Unit>)

The receiver is marked with an IMMUTABLE descriptor, but its subobjects have not yet been made immutable. Scan them now, and do any additional fix-ups necessary for the kind of object.

Link copied to clipboard
abstract fun makeShared(): AvailObject

Dispatch to the descriptor.

Link copied to clipboard
abstract fun makeSharedInternal(queueToProcess: MutableList<AvailObject>, fixups: MutableList<() -> Unit>)

The receiver is marked with a SHARED descriptor, but its subobjects have not yet been made shared. Scan them now, and do any additional fix-ups necessary for the kind of object.

Link copied to clipboard

Dispatch to the descriptor.

Link copied to clipboard

Dispatch to the descriptor.

Link copied to clipboard
open fun <T : A_BasicObject, O : A_BasicObject> mapNotNil(action: (T) -> O): O

If the receiver is notNil, evaluate the action with it, answering the value produced by the action. If the receiver was nil, answer nil cast to the action's output type.

Link copied to clipboard
abstract fun marshalToJava(classHint: Class<*>?): Any?
Link copied to clipboard
fun A_Number.minusCanDestroy(aNumber: A_Number, canDestroy: Boolean): A_Number

Subtract the argument aNumber from a receiver and answer the result.

Link copied to clipboard

Multiply the receiver by the given double, destroying one or the other if it's mutable and canDestroy is true. Because of the requirement that the argument be a double rather than an arbitrary A_Number, this is usually only used for double-dispatching.

Link copied to clipboard

Multiply the receiver by the given float, destroying one or the other if it's mutable and canDestroy is true. Because of the requirement that the argument be a float rather than an arbitrary A_Number, this is usually only used for double-dispatching.

Link copied to clipboard

Multiply the receiver by the infinity with the given sign, potentially destroying the receiver if it's mutable and canDestroy is true.

Link copied to clipboard

Multiply the receiver by the given integer, destroying one or the other if it's mutable and canDestroy is true. Because of the requirement that the argument be an integer rather than an arbitrary A_Number, this is usually only used for double-dispatching.

Link copied to clipboard
abstract fun nameForDebugger(): String

Answer a name suitable for labeling a field containing this object.

Link copied to clipboard

Divide the receiver by the argument aNumber and answer the result. The operation is not allowed to fail, so the caller must ensure that the arguments are valid, i.e. the divisor is not zero.

Link copied to clipboard

Difference the receiver and the argument aNumber and answer the result. The operation is not allowed to fail, so the caller must ensure that the arguments are valid, i.e. not infinities of like sign.

Link copied to clipboard

Add the receiver and the argument aNumber and answer the result. The operation is not allowed to fail, so the caller must ensure that the arguments are valid, i.e. not infinities of unlike sign.

Link copied to clipboard

Multiply the receiver and the argument aNumber and answer the result. The operation is not allowed to fail, so the caller must ensure that the arguments are valid, i.e. not zero and infinity.

Link copied to clipboard

Answer an ordering between the receiver and the argument. This compares the underlying real numeric values of the two A_Numbers, which does not necessarily agree with the equals semantics. In particular, under numerical ordering, 5 = 5.0 = 5.0f, and 0.0/0.0 is incomparable to every number, even itself. Under ordinary equality (the equals method), an integer never equals a float, and neither ever equals a double. However, 0.0/0.0 is equal to 0.0/0.0, since they have the same kind (double) and the same bit pattern. Note that hash agrees with general equality, not the numeric ordering.

Link copied to clipboard

This produces the same value as numericCompare, but the argument is an unboxed double value.

Link copied to clipboard

This produces the same value as numericCompare, but the argument is known to be an integral infinity whose Sign is provided.

Link copied to clipboard

This produces the same value as numericCompare, but the argument is known to be an integer.

Link copied to clipboard
abstract fun objectSlotsCount(): Int

Answer the number of object slots in this AvailObject. All variable object slots occur following the last fixed object slot.

Link copied to clipboard
fun A_Number.plusCanDestroy(aNumber: A_Number, canDestroy: Boolean): A_Number

Add the receiver and the argument aNumber and answer the result.

Link copied to clipboard
abstract fun pojoSelfType(): A_Type
Link copied to clipboard
abstract fun printOnAvoidingIndent(builder: StringBuilder, recursionMap: IdentityHashMap<A_BasicObject, Void>, indent: Int)

Recursively print the receiver to the builder unless it is already present in the recursionMap. Printing will begin at the specified indent level, measured in horizontal tab characters.

Link copied to clipboard
abstract fun rawPojo(): AvailObject
Link copied to clipboard

Extract a (signed) base 2^32 digit from the integer. The index must be in range for the integer's representation.

Link copied to clipboard

Replace a (signed) base 2^32 digit of the integer. The index must be in range for the integer's representation, and the receiver must be mutable.

Link copied to clipboard

Extract an unsigned base 2^32 digit from the integer. The index must be in range for the integer's representation.

Link copied to clipboard

Replace an unsigned base 2^32 digit of the integer. The index must be in range for the integer's representation, and the receiver must be mutable.

Link copied to clipboard

Dispatch to the descriptor.

Link copied to clipboard
abstract fun resultType(): A_Type
Link copied to clipboard
abstract fun sameAddressAs(anotherObject: A_BasicObject): Boolean

Answer whether the objects occupy the same memory addresses.

Link copied to clipboard
abstract fun scanSubobjects(visitor: (AvailObject) -> AvailObject)

Dispatch to the descriptor.

Link copied to clipboard
Link copied to clipboard
abstract fun setDescriptor(newDescriptor: AbstractDescriptor)

Replace the object's {@linkplain AbstractDescriptor descriptor}.

Link copied to clipboard
abstract fun setHashOrZero(value: Int)

Dispatch to the descriptor.

Link copied to clipboard
abstract fun setToInvalidDescriptor()

Replace my descriptor field with a FillerDescriptor. This blows up for most messages, catching incorrect (all, by definition) further accidental uses of this object.

Link copied to clipboard

Answer whether to show value-specific content in the file name for the debugger.

Link copied to clipboard

Subtract the receiver from the given double, destroying one or the other if it's mutable and canDestroy is true. Because of the requirement that the argument be a double rather than an arbitrary A_Number, this is usually only used for double-dispatching.

Link copied to clipboard

Subtract the receiver from the given float, destroying one or the other if it's mutable and canDestroy is true. Because of the requirement that the argument be a float rather than an arbitrary A_Number, this is usually only used for double-dispatching.

Link copied to clipboard

Subtract the receiver from the infinity with the specified sign, destroying one or the other if it's mutable and canDestroy is true.

Link copied to clipboard

Subtract the receiver from the given integer, destroying one or the other if it's mutable and canDestroy is true.

Link copied to clipboard
inline fun <R> A_BasicObject.synchronizeIf(syncCondition: Boolean, body: A_BasicObject.() -> R): R

If the provided condition is true, synchronize with the receiver's monitor around the execution of the body function. Otherwise, run the body function without synchronization.

Link copied to clipboard
fun A_Number.timesCanDestroy(aNumber: A_Number, canDestroy: Boolean): A_Number

Multiply the receiver and the argument aNumber and answer the result.

Link copied to clipboard
abstract fun traversed(): AvailObject

Follow indirections until a non-indirection is reached. Replace each indirection's target with the ultimate target.

Link copied to clipboard

Follow indirections until a non-indirection is reached. Replace each indirection's target with the ultimate target, even if it would cause the otherwise-forbidden immutable->mutable references. Only used during makeImmutable.

Link copied to clipboard

Follow indirections until a non-indirection is reached. Replace each indirection's target with the ultimate target, even if it would cause the otherwise-forbidden shared->unshared references. Only used during makeShared.

Link copied to clipboard

Normalize the integer to have the minimum number of base 2^32 digits.

Link copied to clipboard

Answer the number of variable integer slots in this object. This does not include the fixed integer slots.

Link copied to clipboard

Answer the number of variable object slots in this AvailObject. This does not include the fixed object slots.

Link copied to clipboard
abstract fun writeSummaryTo(writer: JSONWriter)
Link copied to clipboard
abstract fun writeTo(writer: JSONWriter)