Skip to content

Commit

Permalink
format
Browse files Browse the repository at this point in the history
  • Loading branch information
janmasrovira committed Nov 27, 2024
1 parent a6abb99 commit 0080f0c
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 4 deletions.
6 changes: 5 additions & 1 deletion Stdlib/Trait/Eq.juvix
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,11 @@ import Stdlib.Data.Fixity open;
--- A trait defining equality
builtin eq
trait
type Eq A := mkEq@{builtin isEqual eq : A -> A -> Bool};
type Eq A :=
mkEq@{
builtin isEqual
eq : A -> A -> Bool;
};

syntax operator == comparison;
syntax operator /= comparison;
Expand Down
5 changes: 4 additions & 1 deletion Stdlib/Trait/Ord.juvix
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,10 @@ orderingEqI : Eq Ordering;

--- A trait for defining a total order
trait
type Ord A := mkOrd@{cmp : A -> A -> Ordering};
type Ord A :=
mkOrd@{
cmp : A -> A -> Ordering;
};

syntax operator <= comparison;

Expand Down
5 changes: 4 additions & 1 deletion Stdlib/Trait/Partial.juvix
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,10 @@ import Stdlib.Data.String.Base open;
import Stdlib.Debug.Fail as Debug;

trait
type Partial := mkPartial@{fail : {A : Type} -> String -> A};
type Partial :=
mkPartial@{
fail : {A : Type} -> String -> A;
};

open Partial public;

Expand Down
5 changes: 4 additions & 1 deletion Stdlib/Trait/Show.juvix
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,7 @@ module Stdlib.Trait.Show;
import Stdlib.Data.String.Base open;

trait
type Show A := mkShow@{show : A -> String};
type Show A :=
mkShow@{
show : A -> String;
};

0 comments on commit 0080f0c

Please sign in to comment.