Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
stdpp
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
47
Issues
47
List
Boards
Labels
Service Desk
Milestones
Merge Requests
3
Merge Requests
3
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Iris
stdpp
Commits
4112556c
Commit
4112556c
authored
Nov 04, 2018
by
Robbert Krebbers
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Consistently block `simpl` on all `Z` operations.
parent
2776d930
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
2 deletions
+23
-2
README.md
README.md
+7
-0
theories/numbers.v
theories/numbers.v
+16
-2
No files found.
README.md
View file @
4112556c
...
...
@@ -33,6 +33,13 @@ Notably:
*
The behavior of
`Program`
is tweaked:
`Unset Transparent Obligations`
,
`Obligation Tactic := idtac`
,
`Add Search Blacklist "_obligation_"`
. See
[
`base.v`
](
theories/base.v
)
for further details.
*
It blocks
`simpl`
on all operations on integers
`Z`
(by setting
`Arguments op : simpl never`
). We do this because
`simpl`
tends to expose
their internals (e.g. try
`simpl`
on
`Z.of_nat (S n) + y`
).
As a consequence of blocking
`simpl`
, due to
[
Coq bug #5039
](
https://github.com/coq/coq/issues/5039
)
the
`omega`
tactic
sometimes fails. We do not consider this an issue since we use
`lia`
(for
which the aforementioned Coq bug was fixed) instead of
`omega`
anywhere.
## Prerequisites
...
...
theories/numbers.v
View file @
4112556c
...
...
@@ -283,17 +283,31 @@ Proof.
split
.
apply
Z
.
quot_pos
;
lia
.
trans
x
;
auto
.
apply
Z
.
quot_lt
;
lia
.
Qed
.
(* Note that we cannot disable simpl for [Z.of_nat] as that would break
tactics as [lia]. *)
Arguments
Z
.
pred
:
simpl
never
.
Arguments
Z
.
succ
:
simpl
never
.
Arguments
Z
.
of_nat
:
simpl
never
.
Arguments
Z
.
to_nat
:
simpl
never
.
Arguments
Z
.
mul
:
simpl
never
.
Arguments
Z
.
add
:
simpl
never
.
Arguments
Z
.
sub
:
simpl
never
.
Arguments
Z
.
opp
:
simpl
never
.
Arguments
Z
.
pow
:
simpl
never
.
Arguments
Z
.
div
:
simpl
never
.
Arguments
Z
.
modulo
:
simpl
never
.
Arguments
Z
.
quot
:
simpl
never
.
Arguments
Z
.
rem
:
simpl
never
.
Arguments
Z
.
shiftl
:
simpl
never
.
Arguments
Z
.
shiftr
:
simpl
never
.
Arguments
Z
.
gcd
:
simpl
never
.
Arguments
Z
.
lcm
:
simpl
never
.
Arguments
Z
.
min
:
simpl
never
.
Arguments
Z
.
max
:
simpl
never
.
Arguments
Z
.
lor
:
simpl
never
.
Arguments
Z
.
land
:
simpl
never
.
Arguments
Z
.
lxor
:
simpl
never
.
Arguments
Z
.
lnot
:
simpl
never
.
Arguments
Z
.
square
:
simpl
never
.
Arguments
Z
.
abs
:
simpl
never
.
Lemma
Z_to_nat_neq_0_pos
x
:
Z
.
to_nat
x
≠
0
%
nat
→
0
<
x
.
Proof
.
by
destruct
x
.
Qed
.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment