Hoogle Search

Within LTS Haskell 24.28 (ghc-9.10.3)

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

  1. toList :: DomCodCnt l r => Bimap l r -> [(Dom l, Dom r)]

    bimaps Data.Bijection.Class

    No documentation available.

  2. toListDC :: DomCod z => z -> [(Dom z, Cod z)]

    bimaps Data.Bijection.Class

    No documentation available.

  3. module Data.BinaryList

    Binary lists are lists whose number of elements is a power of two. This data structure is efficient for some computations like:

    • Splitting a list in half.
    • Appending two lists of the same length.
    • Extracting an element from the list.
    All the functions exported are total except for fromListWithDefault. It is impossible for the user of this library to create a binary list whose length is not a power of two. Since many names in this module clash with the names of some Prelude functions, you probably want to import this module this way:
    import Data.BinaryList (BinList,Exponent)
    import qualified Data.BinaryList as BL
    
    Remember that binary lists are an instance of the Foldable and Traversable classes. If you are missing a function here, look for functions using those instances. Note that some functions like replicate, generate, or take, don't use the length of the list as argument, but the exponent of its length expressed as a power of two. Throughout this document, this is referred as the length exponent. For example, if the list has length 16, its length exponent is 4 since 2^4 = 16. Therefore replicate 4 0 will create a list with 16 zeroes. Keep this in mind when using this library. Note as well that this implies that there is no need to check that the length argument is or is not a power of two.

  4. data BinList a

    binary-list Data.BinaryList

    A binary list is a list containing a power of two elements. Note that a binary list is never empty because it has at least 2^0 = 1 element.

  5. fromList :: [a] -> Maybe (BinList a)

    binary-list Data.BinaryList

    O(n). Build a binary list from a linked list. If the input list has length different from a power of two, it returns Nothing.

  6. fromListSplit :: a -> Exponent -> [a] -> (BinList a, [a])

    binary-list Data.BinaryList

    O(n). Build a binary list from a linked list. It returns a binary list with length 2 ^ n (where n is the supplied Int argument), and the list of elements of the original list that were not used. If the input list is shorter than 2 ^ n, a default element will be used to complete the binary list. This method for building binary lists is faster than both fromList and fromListWithDefault.

  7. fromListWithDefault :: a -> [a] -> BinList a

    binary-list Data.BinaryList

    O(n). Build a binary list from a linked list. If the input list has length different from a power of two, fill to the next power of two with a default element. Warning: this function crashes if the input list length is larger than any power of two in the type Int. However, this is very unlikely.

  8. toListFilter :: (a -> Bool) -> BinList a -> [a]

    binary-list Data.BinaryList

    O(n). Create a list from the elements of a binary list matching a given condition.

  9. toListSegment :: Int -> Int -> BinList a -> [a]

    binary-list Data.BinaryList

    O(n). Create a list extracting a sublist of elements from a binary list.

  10. data DecodedBinList a

    binary-list Data.BinaryList.Serialize

    A binary list decoded, from where you can extract a binary list. If the decoding process fails in some point, you still will be able to retrieve the binary list of elements that were decoded successfully before the error.

Page 185 of many | Previous | Next