Skip to content

Commit

Permalink
Comments
Browse files Browse the repository at this point in the history
  • Loading branch information
rossberg committed May 10, 2023
1 parent c7752e1 commit 4458f9c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions document/core/syntax/instructions.rst
Original file line number Diff line number Diff line change
Expand Up @@ -528,10 +528,10 @@ Similarly, :ref:`arrays <syntax-type-array>` can be allocated either with an exp
Furthermore, |ARRAYNEWFIXED| allocates an array with statically fixed size,
and |ARRAYNEWDATA| and |ARRAYNEWELEM| allocate an array and initialize it from a :ref:`data <syntax-data>` or :ref:`element <syntax-elem>` segement, respectively.
The remaining array instructions access individual slots,
again allowing for different sign extension modes in the case of :ref:`packed <syntax-type-packed>` a storage type.
again allowing for different sign extension modes in the case of a :ref:`packed <syntax-type-packed>` storage type.
Last, |ARRAYLEN| produces the length of an array.

The instructions |I31NEW|, |I31GETS|, and |I31GETU| convert between type |I31| and an unboxed :ref:`scalars <syntax-i31>`.
The instructions |I31NEW|, |I31GETS|, and |I31GETU| convert between type |I31| and an unboxed :ref:`scalar <syntax-i31>`.

The instructions |EXTERNINTERNALIZE| and |EXTERNEXTERNALIZE| allow lossless conversion between references represented as type :math:`(\REF~\NULL~\EXTERN)`| and as :math:`(\REF~\NULL~\ANY)`.

Expand Down
14 changes: 7 additions & 7 deletions document/core/syntax/types.rst
Original file line number Diff line number Diff line change
Expand Up @@ -106,22 +106,22 @@ That is, both type hierarchies are inhabited by an isomorphic set of values, but
A heap type is either *abstract* or *concrete*.

The abstract type |FUNC| denotes the infinite union (i.e., supertype) of all :ref:`function types <syntax-functype>`, regardless of their concrete definition.
Dually, the type |NOFUNC| denotes the infinite intersection (i.e., subtype) of all :ref:`function types <syntax-functype>`, regardless of their concrete definition.
The abstract type |FUNC| denotes the common supertype of all :ref:`function types <syntax-functype>`, regardless of their concrete definition.
Dually, the type |NOFUNC| denotes the common subtype of all :ref:`function types <syntax-functype>`, regardless of their concrete definition.
This type has no values.

The abstract type |EXTERN| denotes the infinite union of all external references received through the :ref:`embedder <embedder>`.
The abstract type |EXTERN| denotes the common supertype of all external references received through the :ref:`embedder <embedder>`.
This type has no concrete subtypes.
Dually, the type |NOEXTERN| denotes the infinite intersection of all forms of external references.
Dually, the type |NOEXTERN| denotes the common subtype of all forms of external references.
This type has no values.

The abstract type |ANY| denotes the infinite union of all aggregate types, as well as possibly abstract values produced by *internalizing* an external reference of type |EXTERN|.
Dually, the type |NONE| denotes the infinite intersection of all forms of aggregate types.
The abstract type |ANY| denotes the common supertype of all aggregate types, as well as possibly abstract values produced by *internalizing* an external reference of type |EXTERN|.
Dually, the type |NONE| denotes the common subtype of all forms of aggregate types.
This type has no values.

The abstract type |EQ| is a subtype of |ANY| that includes all types for which references can be compared, i.e., aggregate values and |I31|.

The abstract types |STRUCT| and |ARRAY| denote the infinite union of all :ref:`structure <syntax-structtype>` and :ref:`array <syntax-arraytype>` aggregates, respectively.
The abstract types |STRUCT| and |ARRAY| denote the common supertypes of all :ref:`structure <syntax-structtype>` and :ref:`array <syntax-arraytype>` aggregates, respectively.

The abstract type |I31| denotes *unboxed scalars*, that is, integers injected into references.
Their observable value range is limited to 31 bits.
Expand Down

0 comments on commit 4458f9c

Please sign in to comment.