You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Nov 3, 2021. It is now read-only.
Copy file name to clipboardExpand all lines: document/core/appendix/algorithm.rst
+54-17Lines changed: 54 additions & 17 deletions
Original file line number
Diff line number
Diff line change
@@ -21,15 +21,49 @@ The algorithm is expressed in typed pseudo code whose semantics is intended to b
21
21
Data Structures
22
22
~~~~~~~~~~~~~~~
23
23
24
+
Types are representable as an enumeration.
25
+
In addition to the plain types from the WebAssembly validation semantics, an extended notion of operand type includes a bottom type `Unknown` that is used as the type of :ref:`polymorphic <polymorphism>` operands.
26
+
27
+
A simple subtyping check can be defined on these types.
28
+
In addition, corresponding functions computing the join (least upper bound) and meet (greatest lower bound) of two types are used.
29
+
Because there is no top type, a join does not exist in all cases.
30
+
Similarly, a meet must always be defined on known value types that exclude the auxiliary bottom type `Unknown`,
31
+
hence a meet does not exist in all cases either.
32
+
A type error is encountered if a join or meet is required when it does not exist.
0 commit comments