Skip to content

Commit

Permalink
Correct condition on absolute value of result.
Browse files Browse the repository at this point in the history
  • Loading branch information
maximebuyse committed Jul 16, 2024
1 parent f4d3d61 commit 1c7733c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion book/src/tutorial/properties.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ Given `value` a field element (a `i32` whose absolute value is at most

- `result ≡ value (mod FIELD_MODULUS)`;
- the absolute value of `result` is bound as follows:
`|result| FIELD_MODULUS / 2 · (|value|/BARRETT_R + 1)`.
`|result| < FIELD_MODULUS`.

It is easy to write this contract directly as `hax::requires` and
`hax::ensures` annotations, as shown in the snippet below.
Expand Down

0 comments on commit 1c7733c

Please sign in to comment.