-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Experimentation with polymorphic task definition.
- Loading branch information
Ian Kariniemi
committed
Apr 9, 2024
1 parent
3069745
commit 79d84d8
Showing
2 changed files
with
52 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
(* Default settings (from HsToCoq.Coq.Preamble) *) | ||
|
||
Generalizable All Variables. | ||
|
||
Unset Implicit Arguments. | ||
Set Maximal Implicit Insertion. | ||
Unset Strict Implicit. | ||
Unset Printing Implicit Defensive. | ||
|
||
Require Coq.Program.Tactics. | ||
Require Coq.Program.Wf. | ||
|
||
(* Preamble *) | ||
|
||
|
||
(* No imports to convert. *) | ||
|
||
(* Converted type declarations: *) | ||
Set Universe Polymorphism. | ||
|
||
Polymorphic Inductive Task (c : (Type -> Type) -> Type) (k : Type) (v : Type) : Type := | ||
| Mk_Task (run : forall {f}, forall `{c f}, (k -> f v) -> f v) : Task c k v. | ||
|
||
Polymorphic Definition Tasks c k v := | ||
(k -> option (Task c k v))%type. | ||
|
||
|
||
Arguments Mk_Task {_} {_} {_} _. | ||
|
||
Definition run {c : (Type -> Type) -> Type} {k : Type} {v : Type} (arg_0__ | ||
: Task c k v) := | ||
let 'Mk_Task run := arg_0__ in | ||
run. | ||
|
||
(* No value declarations to convert. *) | ||
|
||
(* Skipping definition `Build.Task.compose' *) | ||
|
||
(* Skipping definition `Build.Task.liftTask' *) | ||
|
||
(* Skipping definition `Build.Task.liftTasks' *) | ||
|
||
(* External variables: | ||
Type option | ||
*) | ||
|
||
|
||
Definition pidentity {A : Type} (a : A) := a. | ||
|
||
Check pidentity. | ||
Unset Universe Polymorphism. |