Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Paolo G. Giarrusso
iris
Commits
08610b59
Commit
08610b59
authored
Mar 20, 2022
by
Ralf Jung
Committed by
Paolo G. Giarrusso
Mar 20, 2022
Browse files
Doc changes from Ralf
parent
52cc8130
Pipeline
#63558
canceled with stage
in 2 minutes and 7 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
docs/resource_algebras.md
View file @
08610b59
...
...
@@ -20,13 +20,13 @@ Local Existing Instance one_shot_inG.
Here, the projection
`one_shot_inG`
is registered as an instance for type-class
resolution. If you need several resource algebras, just add more
`inG`
fields.
If you are using another module as part of yours, add a field like
`one_shot_other : otherG Σ`
.
`one_shot_other : otherG Σ`
.
All of these fields should be added to the
`Local Existing Instances`
.
The code above enables these typeclass instances only in the surrounding file
:
where they are used to define the new abstraction by the library
, while t
he
The code above enables these typeclass instances only in the surrounding file
where they are used to define the new abstraction
s
by the library
. T
he
interface of these abstractions will only depend on the
`one_shotG`
class.
Since
`one_shot_inG`
will be hidden from clients, they will not accidentally
re
use it accidentally
in their code.
re
ly on it
in their code.
Having defined the type class, we need to provide a way to instantiate it. This
is an important step, as not every resource algebra can actually be used: if
...
...
Write
Preview
Supports
Markdown
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