java.lang.Object
java.lang.Record
org.kink_lang.kink.internal.callstack.Trace
- Record Components:
symHandle- the sym handle.location- the location.isTail- whether it is on the tail.
A trace of a call.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanisTail()Returns the value of theisTailrecord component.location()Returns the value of thelocationrecord component.static Traceof(int symHandle) Returns a trace frame with the sym handle.static TraceReturns a trace frame with the sym handle and the location, not on the tail.static TraceReturns a trace frame with the location.static TraceofTail(int symHandle) Returns a trace of a taill call with the sym handle.onTail()Returns a trace on tail, with the same symHandle and location.intReturns the value of thesymHandlerecord component.final StringtoString()Returns a string representation of this record class.toTraceVal(Vm vm) Returns the val representing the trace.
-
Field Details
-
SNIP
The trace which represents snipping of traces; it has neither sym handle nor location.
-
-
Constructor Details
-
Trace
Constructs a trace.- Parameters:
symHandle- the sym handle.location- the location.isTail- whether it is on the tail.
-
-
Method Details
-
of
Returns a trace frame with the sym handle.- Parameters:
symHandle- the sym handle.- Returns:
- a trace frame with the sym handle.
-
ofTail
Returns a trace of a taill call with the sym handle.- Parameters:
symHandle- the sym handle.- Returns:
- a trace of a taill call with the sym handle.
-
of
Returns a trace frame with the location.- Parameters:
location- the location.- Returns:
- a trace frame with the location.
-
of
Returns a trace frame with the sym handle and the location, not on the tail.- Parameters:
symHandle- the sym handle.location- the location.- Returns:
- a trace frame with the sym handle and the location, not on the tail.
-
onTail
Returns a trace on tail, with the same symHandle and location.- Returns:
- a trace on tail, with the same symHandle and location.
-
toTraceVal
Returns the val representing the trace.- Parameters:
vm- the vm.- Returns:
- the trace val.
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
symHandle
public int symHandle()Returns the value of thesymHandlerecord component.- Returns:
- the value of the
symHandlerecord component
-
location
Returns the value of thelocationrecord component.- Returns:
- the value of the
locationrecord component
-
isTail
public boolean isTail()Returns the value of theisTailrecord component.- Returns:
- the value of the
isTailrecord component
-