File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ import Result
1414import Maybe
1515import Bool
1616
17- data List a where Empty; Next a (List a)
17+ data List a where Empty | Next a (List a)
1818
1919--- Append two lists
2020append_list : forall {a : Type} . List a -> List a -> List a
Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ import List
1010
1111data Labels = Toss | Drop
1212
13- -- Operations
13+ -- (Sigma functor) - Signature of operations
1414data GameOps : Set Labels -> Type -> Type where
1515 FlipCoin : forall {r : Type} . () -> (Bool -> r) [2] -> GameOps {Toss} r;
1616 Fumble : forall {r : Type} . () -> (Void -> r) [0] -> GameOps {Drop} r
@@ -33,7 +33,7 @@ foo = call FlipCoin ()
3333
3434-- Two coin flips, all good
3535example1 : (Bool, Bool) <Eff (Set Labels) GameOps {Toss}>
36- example1 = let
36+ example1 = let -- do x <- ...
3737 x <- call FlipCoin ();
3838 y <- call FlipCoin ()
3939 in pure (x, y)
You can’t perform that action at this time.
0 commit comments