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
Copy file name to clipboardExpand all lines: document/core/appendix/properties.rst
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -828,7 +828,7 @@ the standard soundness theorems hold. [#cite-cpp2018]_ [#cite-fm2021]_
828
828
829
829
**Theorem (Preservation).**
830
830
If a :ref:`configuration <syntax-config>` :math:`S;P^\ast` is :ref:`valid <valid-config>` with :ref:`result type <syntax-resulttype>` :math:`[t^\ast]^\ast` (i.e., :math:`\vdashconfig S;P^\ast : [t^\ast]^\ast`),
831
-
and steps to :math:`S';P'^\ast` (i.e., :math:`S;P^\ast\stepto S';P'^\ast`),
831
+
and steps to :math:`S';P'^\ast` (i.e., :math:`S;P^\ast\stepto^{\evt} S';P'^\ast`),
832
832
then :math:`S';P'^\ast` is a valid configuration with the same result type (i.e., :math:`\vdashconfig S';P'^\ast : [t^\ast]^\ast`).
833
833
Furthermore, :math:`S'` is an :ref:`extension <extend-store>` of :math:`S` (i.e., :math:`\vdashstoreextends S \extendsto S'`).
834
834
@@ -838,13 +838,13 @@ A terminal configuration is a configuration whose threads are all terminal.
838
838
**Theorem (Progress).**
839
839
If a :ref:`configuration <syntax-config>` :math:`S;P^\ast` is :ref:`valid <valid-config>` (i.e., :math:`\vdashconfig S;P^\ast : [t^\ast]^\ast` for some :ref:`result type <syntax-resulttype>` :math:`[t^\ast]^\ast`),
840
840
then either it is terminal,
841
-
or it can step to some configuration :math:`S';P'^\ast` (i.e., :math:`S;P^\ast\stepto S';P'^\ast`).
841
+
or it can step to some configuration :math:`S';P'^\ast` (i.e., :math:`S;P^\ast\stepto^{\evt} S';P'^\ast`).
842
842
843
843
From Preservation and Progress the soundness of the WebAssembly type system follows directly.
844
844
845
845
**Corollary (Soundness).**
846
846
If a :ref:`configuration <syntax-config>` :math:`S;P^\ast` is :ref:`valid <valid-config>` (i.e., :math:`\vdashconfig S;P^\ast : [t^\ast]^\ast` for some :ref:`result type <syntax-resulttype>` :math:`[t^\ast]^\ast`),
847
-
then it either diverges or takes a finite number of steps to reach a terminal configuration :math:`S';P'^\ast` (i.e., :math:`S;P^\ast\stepto^\ast S';P'^\ast`) that is valid with the same result type (i.e., :math:`\vdashconfig S';P'^\ast : [t^\ast]^\ast`)
847
+
then it either diverges or takes a finite number of steps to reach a terminal configuration :math:`S';P'^\ast` (i.e., :math:`S;P^\ast\stepto^{\ast~(\evt^\ast)} S';P'^\ast`) that is valid with the same result type (i.e., :math:`\vdashconfig S';P'^\ast : [t^\ast]^\ast`)
848
848
and where :math:`S'` is an :ref:`extension <extend-store>` of :math:`S` (i.e., :math:`\vdashstoreextends S \extendsto S'`).
849
849
850
850
In other words, every thread in a valid configuration either runs forever, traps, or terminates with a result that has the expected type.
0 commit comments