Skip to content

Commit

Permalink
stylistic changes
Browse files Browse the repository at this point in the history
  • Loading branch information
lukaszcz committed Jan 31, 2023
1 parent 30ca331 commit 5c58491
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
10 changes: 5 additions & 5 deletions src/Juvix/Compiler/Backend/Geb/Extra.hs
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ destructProduct = \case
objectBool :: Object
objectBool = ObjectCoproduct (Coproduct ObjectTerminal ObjectTerminal)

gebTrue :: Morphism
gebTrue = MorphismLeft MorphismUnit
morphismTrue :: Morphism
morphismTrue = MorphismLeft MorphismUnit

gebFalse :: Morphism
gebFalse = MorphismRight MorphismUnit
morphismFalse :: Morphism
morphismFalse = MorphismRight MorphismUnit

mkOr :: Morphism -> Morphism -> Morphism
mkOr arg1 arg2 =
Expand All @@ -31,7 +31,7 @@ mkOr arg1 arg2 =
Lambda
{ _lambdaVarType = ObjectTerminal,
_lambdaBodyType = objectBool,
_lambdaBody = gebTrue
_lambdaBody = morphismTrue
},
_caseRight =
MorphismLambda
Expand Down
3 changes: 2 additions & 1 deletion src/Juvix/Compiler/Backend/Geb/Language.hs
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ data Binop = Binop
_binopRight :: Morphism
}

-- | Corresponds to the GEB type for morphisms (terms): `stlc`
-- | Corresponds to the GEB type for terms (morphisms of the category): `stlc`
-- (https://github.com/anoma/geb/blob/main/src/specs/lambda.lisp).
data Morphism
= MorphismAbsurd Morphism
Expand Down Expand Up @@ -150,6 +150,7 @@ makeLenses ''First
makeLenses ''Second
makeLenses ''Lambda
makeLenses ''Var
makeLenses ''Binop
makeLenses ''Application
makeLenses ''Morphism
makeLenses ''Product
Expand Down

0 comments on commit 5c58491

Please sign in to comment.