Skip to content

Commit

Permalink
drop unnceccesary comments
Browse files Browse the repository at this point in the history
  • Loading branch information
lemastero committed Jun 25, 2022
1 parent 0fef09a commit de2513b
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions src/Data/Wedge.agda
Original file line number Diff line number Diff line change
Expand Up @@ -100,10 +100,11 @@ swap (there b) = here b
-- Wedge associativity

reassocLR : Wedge (Wedge A B) C -> Wedge A (Wedge B C)
reassocLR (here (here a)) = here a
reassocLR (here (there b)) = there (here b)
reassocLR (there c) = there (there c)
reassocLR _ = nowhere
reassocLR (here (there b)) = there (here b)
reassocLR (here (here a)) = here a
reassocLR (here nowhere) = nowhere
reassocLR nowhere = nowhere

reassocRL : Wedge A (Wedge B C) -> Wedge (Wedge A B) C
reassocRL nowhere = nowhere
Expand All @@ -112,8 +113,6 @@ reassocRL (there nowhere) = nowhere
reassocRL (there (here b)) = here (there b)
reassocRL (there (there c)) = there c

--

-- conversions

fromSum : A + B -> Wedge A B
Expand All @@ -126,8 +125,6 @@ quotWedge (left nothing) = nowhere
quotWedge (right (just b)) = there b
quotWedge (right nothing) = nowhere

-- 1 + (A + B) <=> Wedge A B

-- collapses both nothing into single nowhere
toWedge : Maybe (A + B) -> Wedge A B
toWedge (just (left a)) = here a
Expand All @@ -141,12 +138,10 @@ fromWedge (there b) = just (right b)

-- projections

-- TODO fromHere (quotWedge Nothing mb) = mb
fromHere : Wedge A B -> Maybe A
fromHere (here a) = just a
fromHere _ = nothing

-- TODO fromThere (quotWedge ma Nothing) = ma
fromThere : Wedge A B -> Maybe B
fromThere (there b) = just b
fromThere _ = nothing
Expand Down

0 comments on commit de2513b

Please sign in to comment.