Hoogle Search
Within LTS Haskell 24.6 (ghc-9.10.2)
Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.
map :: forall a b (n :: Nat) . (a -> b) -> Vec n a -> Vec n bclash-prelude Clash.Explicit.Prelude.Safe "map f xs" is the vector obtained by applying f to each element of xs, i.e.,
map f (x1 :> x2 :> ... :> xn :> Nil) == (f x1 :> f x2 :> ... :> f xn :> Nil)
and corresponds to the following circuit layout:map :: forall a b (n :: Nat) . (a -> b) -> Vec n a -> Vec n bclash-prelude Clash.Prelude "map f xs" is the vector obtained by applying f to each element of xs, i.e.,
map f (x1 :> x2 :> ... :> xn :> Nil) == (f x1 :> f x2 :> ... :> f xn :> Nil)
and corresponds to the following circuit layout:map :: forall a b (n :: Nat) . (a -> b) -> Vec n a -> Vec n bclash-prelude Clash.Prelude.Safe "map f xs" is the vector obtained by applying f to each element of xs, i.e.,
map f (x1 :> x2 :> ... :> xn :> Nil) == (f x1 :> f x2 :> ... :> f xn :> Nil)
and corresponds to the following circuit layout:map :: forall a b (n :: Nat) . (a -> b) -> Vec n a -> Vec n bclash-prelude Clash.Sized.Vector "map f xs" is the vector obtained by applying f to each element of xs, i.e.,
map f (x1 :> x2 :> ... :> xn :> Nil) == (f x1 :> f x2 :> ... :> f xn :> Nil)
and corresponds to the following circuit layout:map :: C sh => T (Map k sh) -> Map k (T sh)comfort-blas Numeric.BLAS.Slice QC.forAll (fmap shapeInt $ QC.choose (0,100)) $ \shapeA -> QC.forAll (fmap shapeInt $ QC.choose (0,100)) $ \shapeB -> QC.forAll (fmap shapeInt $ QC.choose (0,100)) $ \shapeC -> QC.forAll (genSlice2 (Map.fromList $ ('a', shapeA) : ('b', shapeB) : ('c', shapeC) : []) (shapeA ::+ shapeB ::+ shapeC)) $ \(sliceMap, sliceParted) -> Slice.map sliceMap Map.! 'b' == Slice.left (Slice.right sliceParted)
QC.forAll (QC.choose (0,100)) $ \numRows -> QC.forAll (QC.choose (0,100)) $ \numColumns -> let rowShape = shapeInt numRows; columnShape = shapeInt numColumns; mapShape_ = Map.fromList $ map (\k -> (k, columnShape)) (Shape.indices rowShape) in QC.forAll (genSlice2 mapShape_ (rowShape, columnShape)) $ \(sliceMap, sliceMatrix) -> Map.toAscList (Slice.map sliceMap) == Array.toAssociations (Slice.rowArray sliceMatrix)
map :: forall i o u (m :: Type -> Type) . (i -> o) -> Pipe i o u m uconduino Data.Conduino.Combinators Process every incoming item with a pure function, and yield its output.
map :: (a -> b) -> IntervalMap k a -> IntervalMap k bdata-interval Data.IntervalMap.Lazy Map a function over all values in the map.
map :: (a -> b) -> IntervalMap k a -> IntervalMap k bdata-interval Data.IntervalMap.Strict Map a function over all values in the map.
-
dimensional Numeric.Units.Dimensional.Prelude map f xs is the list obtained by applying f to each element of xs, i.e.,
map f [x1, x2, ..., xn] == [f x1, f x2, ..., f xn] map f [x1, x2, ...] == [f x1, f x2, ...]
this means that map id == idExamples
>>> map (+1) [1, 2, 3] [2,3,4]
>>> map id [1, 2, 3] [1,2,3]
>>> map (\n -> 3 * n + 1) [1, 2, 3] [4,7,10]
-
distribution-opensuse OpenSuse.Prelude map f xs is the list obtained by applying f to each element of xs, i.e.,
map f [x1, x2, ..., xn] == [f x1, f x2, ..., f xn] map f [x1, x2, ...] == [f x1, f x2, ...]
this means that map id == idExamples
>>> map (+1) [1, 2, 3] [2,3,4]
>>> map id [1, 2, 3] [1,2,3]
>>> map (\n -> 3 * n + 1) [1, 2, 3] [4,7,10]