flix

0.67.2

Fixpoint3.BoxingType

Type Aliases

type alias Boxing[r: Eff] = (Vector[MutList[Boxed, r]], Vector[BPlusTree[Boxed, Int64, r]], TypeInfo[r], Vector[ReadWriteLock[r]]) Source

Boxing=(values, valueToRep, typeInfo, locks) contains the information needed to convert between Boxed objects and their Int64 representation

The i'th value of each Vector belongs to a specific UnifiedTypePos. The description of the values will be for some i.

valueToRep maps Boxed objects to their Int64 representation.

values contains the Boxed objects being stored.

The following invariant is kept: values(valueToRep[boxedValue]) == boxedValue. This design limits us to 2^32 objects of a given type.

Furthermore, for lattice Bot should be represented by 0.

typeInfo[i] records which type of values are associated with the information stored at i. If we have yet to meet any values associated with position i, typeInfo[i] will be Unknown.

locks[i] must be acquired before a specific values[i] can be interacted with.

type alias UnifiedTypePos = Int32 Source

Describes the placement of type-information of a group of values that share the same type.

Definitions

def getType(index: Int32, typeInfo: TypeInfo[r]): Types \ r Source

Return the type of value saved at index in typeInfo.

def setType(t: Types, index: UnifiedTypePos, typeInfo: TypeInfo[r]): Unit \ r Source

Store the type t of a value saved at index in typeInfo.