Skip to content

Commit

Permalink
Remove unused names (#52)
Browse files Browse the repository at this point in the history
  • Loading branch information
thomashoneyman committed Jun 16, 2021
1 parent 2a2e02e commit 3f12411
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/Data/Functor/Variant.purs
Expand Up @@ -94,7 +94,7 @@ class FoldableVFRL rl row <= TraversableVFRL rl row | rl -> row where
traverseVFRL :: forall proxy f a b. Applicative f => proxy rl -> (a -> f b) -> VariantF row a -> f (VariantF row b)

instance traversableNil :: TraversableVFRL RL.Nil () where
traverseVFRL _ f = case_
traverseVFRL _ _ = case_

instance traversableCons ::
( IsSymbol k
Expand Down
3 changes: 0 additions & 3 deletions src/Data/Variant.purs
Expand Up @@ -319,9 +319,6 @@ instance enumVariantCons ∷ (VariantBoundedEnums rs, BoundedEnum a) ⇒ Variant
, cardinality: coerceCardinality cardinality
}

coerceA a VariantCase
coerceA = unsafeCoerce

coerceAToMbA (a Maybe a) VariantCase Maybe VariantCase
coerceAToMbA = unsafeCoerce

Expand Down
4 changes: 2 additions & 2 deletions src/Data/Variant/Internal.purs
Expand Up @@ -174,7 +174,7 @@ lookupPred (VariantRep rep) = go1
| otherwise → go2 t1 b1 d1 ts1 bs1 ds1
_, _, _ → impossible "pred"

go2 t1 b1 d1 = case _, _, _ of
go2 t1 b1 _ = case _, _, _ of
L.Cons t2 ts2, L.Cons b2 bs2, L.Cons d2 ds2
| t2 == rep.type →
case d2.pred rep.value of
Expand All @@ -193,7 +193,7 @@ lookupSucc
lookupSucc (VariantRep rep) = go
where
go = case _, _, _ of
L.Cons t1 ts1, L.Cons b1 bs1, L.Cons d1 ds1
L.Cons t1 ts1, L.Cons _ bs1, L.Cons d1 ds1
| t1 == rep.type →
case d1.succ rep.value of
Just z → Just $ VariantRep { type: t1, value: z }
Expand Down

0 comments on commit 3f12411

Please sign in to comment.