Hoogle Search
Within LTS Haskell 24.19 (ghc-9.10.3)
Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.
smapMaybe :: Stream r ix a => (a -> Maybe b) -> Array r ix a -> Vector DS bmassiv Data.Massiv.Vector Apply a function to each element of the array, while discarding Nothing and keeping the Maybe result.
Examples
-
massiv Data.Massiv.Vector Similar to smapMaybe, but with the Applicative function. Similar to mapMaybe id $ mapM f arr
Examples
concatMapM :: Monad m => (a -> m [b]) -> [a] -> m [b]protolude Protolude.Monad No documentation available.
lazyMapM :: (a -> IO b) -> [a] -> IO [b]MissingH System.IO.Utils Applies a given function to every item in a list, and returns the new list. Unlike the system's mapM, items are evaluated lazily.
prMapMaybeName :: (a -> Maybe b) -> PeriodicReport a c -> PeriodicReport b chledger-lib Hledger.Reports.ReportTypes Map a function over the row names, possibly discarding some.
indexMapMapWithKey :: (a -> b -> c) -> Map (ToOrd a) b -> Map (ToOrd a) cnumeric-prelude MathObj.PartialFraction No documentation available.
unsafeMapMonotonic :: (k -> p -> v -> (q, w)) -> HashPSQ k p v -> HashPSQ k q wpsqueues Data.HashPSQ O(n) Maps a function over the values and priorities of the queue. The function f must be monotonic with respect to the priorities. I.e. if x < y, then fst (f k x v) < fst (f k y v). The precondition is not checked. If f is not monotonic, then the result will be invalid.
unsafeMapMonotonic :: (Key -> p -> v -> (q, w)) -> IntPSQ p v -> IntPSQ q wpsqueues Data.IntPSQ O(n) Maps a function over the values and priorities of the queue. The function f must be monotonic with respect to the priorities. I.e. if x < y, then fst (f k x v) < fst (f k y v). The precondition is not checked. If f is not monotonic, then the result will be invalid.
unsafeMapMonotonic :: forall k p q v w . (k -> p -> v -> (q, w)) -> OrdPSQ k p v -> OrdPSQ k q wpsqueues Data.OrdPSQ O(n) Maps a function over the values and priorities of the queue. The function f must be monotonic with respect to the priorities. I.e. if x < y, then fst (f k x v) < fst (f k y v). The precondition is not checked. If f is not monotonic, then the result will be invalid.
fmapMaybe :: Filterable f => (a -> Maybe b) -> f a -> f breflex Reflex.Class Alias for mapMaybe