Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Iris
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Gaëtan Gilbert
Iris
Commits
72217e38
Commit
72217e38
authored
2 years ago
by
Ralf Jung
Browse files
Options
Downloads
Patches
Plain Diff
fix Known with not-Known Make instances
parent
8e14fcf8
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
iris/proofmode/class_instances_make.v
+12
-4
12 additions, 4 deletions
iris/proofmode/class_instances_make.v
iris/proofmode/classes_make.v
+4
-1
4 additions, 1 deletion
iris/proofmode/classes_make.v
with
16 additions
and
5 deletions
iris/proofmode/class_instances_make.v
+
12
−
4
View file @
72217e38
...
...
@@ -85,10 +85,14 @@ Proof. by rewrite /MakeOr. Qed.
to avoid [emp] in goals involving affine BIs, we give [make_affinely_affine]
a lower cost than [make_affinely_True].
- [make_affinely_default] adds the modality. This is the default instance since
it can always be used, and thus has the highest cost. *)
it can always be used, and thus has the highest cost.
(For this last point, the cost of the [KnownMakeAffinely] instances does not
actually matter, since this is a [MakeAffinely] instance, i.e. an instance of
a different class. What really matters is that the [known_make_affinely]
instance has a lower cost than [make_affinely_default].) *)
Global
Instance
make_affinely_affine
P
:
QuickAffine
P
→
MakeAffinely
P
P
|
0
.
QuickAffine
P
→
Known
MakeAffinely
P
P
|
0
.
Proof
.
apply
affine_affinely
.
Qed
.
Global
Instance
make_affinely_True
:
@
KnownMakeAffinely
PROP
True
emp
|
1
.
Proof
.
by
rewrite
/
KnownMakeAffinely
/
MakeAffinely
affinely_True_emp
.
Qed
.
...
...
@@ -105,10 +109,14 @@ Proof. by rewrite /MakeAffinely. Qed.
it does not really matter since goals in affine BIs typically do not contain
occurrences of [emp] to start with.
- [make_absorbingly_default] adds the modality. This is the default instance
since it can always be used, and thus has the highest cost. *)
since it can always be used, and thus has the highest cost.
(For this last point, the cost of the [KnownMakeAbsorbingly] instances does not
actually matter, since this is a [MakeAbsorbingly] instance, i.e. an instance of
a different class. What really matters is that the [known_make_absorbingly]
instance has a lower cost than [make_absorbingly_default].) *)
Global
Instance
make_absorbingly_absorbing
P
:
QuickAbsorbing
P
→
MakeAbsorbingly
P
P
|
0
.
QuickAbsorbing
P
→
Known
MakeAbsorbingly
P
P
|
0
.
Proof
.
apply
absorbing_absorbingly
.
Qed
.
Global
Instance
make_absorbingly_emp
:
@
KnownMakeAbsorbingly
PROP
emp
True
|
1
.
Proof
.
...
...
This diff is collapsed.
Click to expand it.
iris/proofmode/classes_make.v
+
4
−
1
View file @
72217e38
...
...
@@ -35,7 +35,10 @@ evar, then [MakeX] will not instantiate it arbitrarily.
The reason for this is that if given an evar, these classes would typically
try to instantiate this evar with some arbitrary logical constructs such as
[emp] or [True]. Therefore, we use a [Hint Mode] to disable all the instances
that would have this behavior. *)
that would have this behavior.
In practice this means that usually only the default instance should use [MakeX],
and most specialized instances should use [KnownMakeX]. *)
From
iris
.
bi
Require
Export
bi
.
From
iris
.
prelude
Require
Import
options
.
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment