Hoogle Search

Within LTS Haskell 24.33 (ghc-9.10.3)

Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.

  1. productTypeFrom :: forall a (xs :: [Type]) . IsProductType a xs => a -> NP I xs

    generics-sop Generics.SOP.Universe

    Convert from a product type to its product representation.

  2. productTypeTo :: forall a (xs :: [Type]) . IsProductType a xs => NP I xs -> a

    generics-sop Generics.SOP.Universe

    Convert a product representation to the original type.

  3. productOf :: Num a => Getting (Endo (Endo a)) s a -> s -> a

    diagrams-lib Diagrams.Prelude

    Calculate the Product of every number targeted by a Fold.

    >>> productOf both (4,5)
    20
    
    >>> productOf folded [1,2,3,4,5]
    120
    
    productproductOf folded
    
    This operation may be more strict than you would expect. If you want a lazier version use ala Product . foldMapOf
    productOf :: Num a => Getter s a     -> s -> a
    productOf :: Num a => Fold s a       -> s -> a
    productOf :: Num a => Lens' s a      -> s -> a
    productOf :: Num a => Iso' s a       -> s -> a
    productOf :: Num a => Traversal' s a -> s -> a
    productOf :: Num a => Prism' s a     -> s -> a
    

  4. product3With :: (a -> b -> c -> d) -> [[a]] -> [[b]] -> [[c]] -> [[d]]

    leancheck Test.LeanCheck

    Like productWith, but over 3 lists of tiers.

  5. productMaybeWith :: (a -> b -> Maybe c) -> [[a]] -> [[b]] -> [[c]]

    leancheck Test.LeanCheck

    Take the product of lists of tiers by a function returning a Maybe value discarding Nothing values.

  6. productWith :: (a -> b -> c) -> [[a]] -> [[b]] -> [[c]]

    leancheck Test.LeanCheck

    Take a tiered product of lists of tiers. productWith can be defined by ><, as:

    productWith f xss yss  =  map (uncurry f) $ xss >< yss
    
    (cf. ><)

  7. products :: [[[a]]] -> [[[a]]]

    leancheck Test.LeanCheck

    Takes the product of N lists of tiers, producing lists of length N. Alternatively, takes as argument a list of lists of tiers of elements; returns lists combining elements of each list of tiers.

    products [xss]  =  mapT (:[]) xss
    products [xss,yss]  =  mapT (\(x,y) -> [x,y]) (xss >< yss)
    products [xss,yss,zss]  =  product3With (\x y z -> [x,y,z]) xss yss zss
    

  8. productWith :: (a -> b -> c) -> [[a]] -> [[b]] -> [[c]]

    leancheck Test.LeanCheck.Core

    Take a tiered product of lists of tiers. productWith can be defined by ><, as:

    productWith f xss yss  =  map (uncurry f) $ xss >< yss
    
    (cf. ><)

  9. product3With :: (a -> b -> c -> d) -> [[a]] -> [[b]] -> [[c]] -> [[d]]

    leancheck Test.LeanCheck.Error

    Like productWith, but over 3 lists of tiers.

  10. productMaybeWith :: (a -> b -> Maybe c) -> [[a]] -> [[b]] -> [[c]]

    leancheck Test.LeanCheck.Error

    Take the product of lists of tiers by a function returning a Maybe value discarding Nothing values.

Page 74 of many | Previous | Next