diff options
| author | Pierre-Marie Pédrot | 2015-09-06 13:23:28 +0200 |
|---|---|---|
| committer | Pierre-Marie Pédrot | 2015-09-06 13:23:28 +0200 |
| commit | d8b245d688ff64d17acd9e7591daf6d63b4e54f7 (patch) | |
| tree | 0e202d1f39e97844d94a873b30e4fb14fb481f84 /plugins/extraction/ExtrHaskellZNum.v | |
| parent | c53f2f75375dfffd2f258c76f5b722d37ab0daf9 (diff) | |
| parent | 5080991902a05ee720ab1d6fa1c9d592d3ffd36c (diff) | |
Merge branch 'v8.5'
Diffstat (limited to 'plugins/extraction/ExtrHaskellZNum.v')
| -rw-r--r-- | plugins/extraction/ExtrHaskellZNum.v | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/plugins/extraction/ExtrHaskellZNum.v b/plugins/extraction/ExtrHaskellZNum.v index 3f645db9b1..cbbfda75e5 100644 --- a/plugins/extraction/ExtrHaskellZNum.v +++ b/plugins/extraction/ExtrHaskellZNum.v @@ -12,8 +12,10 @@ Require Import EqNat. Extract Inlined Constant Z.add => "(Prelude.+)". Extract Inlined Constant Z.sub => "(Prelude.-)". Extract Inlined Constant Z.mul => "(Prelude.*)". -Extract Inlined Constant Z.div => "Prelude.div". Extract Inlined Constant Z.max => "Prelude.max". Extract Inlined Constant Z.min => "Prelude.min". Extract Inlined Constant Z_ge_lt_dec => "(Prelude.>=)". Extract Inlined Constant Z_gt_le_dec => "(Prelude.>)". + +Extract Constant Z.div => "(\n m -> if m Prelude.== 0 then 0 else Prelude.div n m)". +Extract Constant Z.modulo => "(\n m -> if m Prelude.== 0 then 0 else Prelude.mod n m)". |
