mirror of
https://github.com/github/semantic.git
synced 2024-12-22 06:11:49 +03:00
Eta-expand storeLookup.
This commit is contained in:
parent
ba6d00f900
commit
26946fce96
@ -25,7 +25,7 @@ deriving instance Functor (Cell l) => Functor (Store l)
|
||||
deriving instance Traversable (Cell l) => Traversable (Store l)
|
||||
|
||||
storeLookup :: Ord l => Address l a -> Store l a -> Maybe (Cell l a)
|
||||
storeLookup = (. unStore) . Map.lookup . unAddress
|
||||
storeLookup (Address address) = Map.lookup address . unStore
|
||||
|
||||
storeLookupAll :: (Ord l, Foldable (Cell l)) => Address l a -> Store l a -> Maybe [a]
|
||||
storeLookupAll address = fmap toList . storeLookup address
|
||||
|
Loading…
Reference in New Issue
Block a user