diff options
| author | Alasdair Armstrong | 2018-08-20 15:30:29 +0100 |
|---|---|---|
| committer | Alasdair Armstrong | 2018-08-20 15:30:29 +0100 |
| commit | 1d7b5f0ddaa6b80babc34180fee5fb4f191283e4 (patch) | |
| tree | 87bfeb74d91651591d36dd81efbe44dce6cb87b7 /lib | |
| parent | 3414ffbc4d62f5cb019def6a6e9931319ac1ffa7 (diff) | |
Add some more test cases for C compilation
Test that basic bi-directional mappings compile correctly
Test that a minimal file importing the prelude compiles correctly
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/flow.sail | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/flow.sail b/lib/flow.sail index b4440eaa..c16763ee 100644 --- a/lib/flow.sail +++ b/lib/flow.sail @@ -1,6 +1,10 @@ $ifndef _FLOW $define _FLOW +val eq_unit : (unit, unit) -> bool + +function eq_unit(_, _) = true + val not_bool = {coq: "negb", _: "not"} : bool -> bool /* NB: There are special cases in Sail for effectful uses of and_bool and or_bool that are not shown here. */ @@ -45,7 +49,7 @@ val gteq_int = {coq: "Z.geb", _:"gteq"} : (int, int) -> bool val lt_int = {coq: "Z.ltb", _:"lt"} : (int, int) -> bool val gt_int = {coq: "Z.gtb", _:"gt"} : (int, int) -> bool -overload operator == = {eq_atom, eq_range, eq_int, eq_bool} +overload operator == = {eq_atom, eq_range, eq_int, eq_bool, eq_unit} overload operator != = {neq_atom, neq_range, neq_int, neq_bool} overload operator | = {or_bool} overload operator & = {and_bool} |
