Hoogle Search

Within LTS Haskell 24.35 (ghc-9.10.3)

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

  1. data DList a

    dlist Data.DList

    A difference list is an abstraction representing a list that supports <math>(1) append and snoc operations, making it useful for replacing frequent applications of ++ such as logging and pretty printing (esp. if those uses of ++ are left-nested).

  2. fromList :: [a] -> DList a

    dlist Data.DList

    fromList xs is a DList representing the list xs. fromList obeys the laws:

    toList . fromList = id
    fromList . toList = id
    
    This function is implemented with ++. Repeated uses of fromList are just as inefficient as repeated uses of ++. If you find yourself doing some form of the following (possibly indirectly), you may not be taking advantage of the DList representation and library:
    fromList . f . toList
    
    More likely, you will convert from a list, perform some operation on the DList, and convert back to a list:
    toList . g . fromList
    

  3. toList :: DList a -> [a]

    dlist Data.DList

    toList xs is the list represented by xs. toList obeys the laws:

    toList . fromList = id
    fromList . toList = id
    
    Evaluating toList xs may “collapse” the chain of function composition underlying many DList functions (append in particular) used to construct xs. This may affect any efficiency you achieved due to laziness in the construction.

  4. fromList :: [a] -> DNonEmpty a

    dlist Data.DList.DNonEmpty

    fromList xs is a DNonEmpty representing the list xs. If xs is empty, an error is raised. fromList obeys the law:

    fromList xs = fromNonEmpty (fromList xs)
    

  5. toList :: DNonEmpty a -> [a]

    dlist Data.DList.DNonEmpty

    toList xs is the non-empty list represented by xs. toList obeys the law:

    toList xs = toList (toNonEmpty xs)
    

  6. decorateList :: [a] -> (a -> Validation) -> Validation

    validity Data.Validity

    Decorate a piecewise validation of a list with their location in the list

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

    utility-ht Data.List.Match

    Returns the shorter one of two lists. It works also for infinite lists as much as possible. E.g.

    >>> shorterList (shorterList (repeat 'a') (repeat 'b')) "abc"
    "abc"
    
    The trick is, that the skeleton of the resulting list is constructed using zipWith without touching the elements. The contents is then computed (only) if requested.

  8. embedDirListing :: FilePath -> Q Exp

    file-embed Data.FileEmbed

    Embed a directory listing recursively in your source code.

    myFiles :: [FilePath]
    myFiles = $(embedDirListing "dirName")
    

  9. parseJSONList :: FromJSON a => Value -> Parser [a]

    yaml Data.Yaml

    No documentation available.

  10. toEncodingList :: ToJSON a => [a] -> Encoding

    yaml Data.Yaml

    No documentation available.

Page 56 of many | Previous | Next