mirror of
https://github.com/github/semantic.git
synced 2024-12-22 14:21:31 +03:00
Define the strengthening of a single-member union.
This commit is contained in:
parent
55934f656b
commit
3dd4d12af8
@ -25,6 +25,11 @@ unwrapU :: (ComonadCofree (Union fs) w, InUnion fs f) => w a -> Maybe (f (w a))
|
||||
unwrapU = prj . unwrap
|
||||
|
||||
|
||||
strengthen :: Union '[f] a -> f a
|
||||
strengthen (Here f) = f
|
||||
strengthen _ = undefined
|
||||
|
||||
|
||||
-- Classes
|
||||
|
||||
class InUnion (fs :: [* -> *]) (f :: * -> *) where
|
||||
|
Loading…
Reference in New Issue
Block a user