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.

  1. sortAnchorLocated :: [GenLocated Anchor a] -> [GenLocated Anchor a]

    ghc-exactprint Language.Haskell.GHC.ExactPrint.Utils

    No documentation available.

  2. sortComments :: [Comment] -> [Comment]

    ghc-exactprint Language.Haskell.GHC.ExactPrint.Utils

    Sort, comparing without span filenames, for CPP injected comments with fake filename

  3. sortEpaComments :: [LEpaComment] -> [LEpaComment]

    ghc-exactprint Language.Haskell.GHC.ExactPrint.Utils

    Sort, comparing without span filenames, for CPP injected comments with fake filename

  4. sortColumnChanged :: TreeSortableClass self => Signal self (IO ())

    gtk Graphics.UI.Gtk.ModelView.TreeSortable

    No documentation available.

  5. sortMulSig :: Ctx -> ScriptOutput -> ScriptOutput

    haskoin-core Haskoin.Script.Standard

    Sort the public keys of a multisig output in ascending order by comparing their compressed serialized representations. Refer to BIP-67.

  6. sortBy :: (a -> a -> Ordering) -> [a] -> [a]

    ihaskell IHaskellPrelude

    The sortBy function is the non-overloaded version of sort. The argument must be finite. The supplied comparison relation is supposed to be reflexive and antisymmetric, otherwise, e. g., for _ _ -> GT, the ordered list simply does not exist. The relation is also expected to be transitive: if it is not then sortBy might fail to find an ordered permutation, even if it exists.

    Examples

    >>> sortBy (\(a,_) (b,_) -> compare a b) [(2, "world"), (4, "!"), (1, "Hello")]
    [(1,"Hello"),(2,"world"),(4,"!")]
    

  7. sortOn :: Ord b => (a -> b) -> [a] -> [a]

    ihaskell IHaskellPrelude

    Sort a list by comparing the results of a key function applied to each element. sortOn f is equivalent to sortBy (comparing f), but has the performance advantage of only evaluating f once for each element in the input list. This is called the decorate-sort-undecorate paradigm, or Schwartzian transform. Elements are arranged from lowest to highest, keeping duplicates in the order they appeared in the input. The argument must be finite.

    Examples

    >>> sortOn fst [(2, "world"), (4, "!"), (1, "Hello")]
    [(1,"Hello"),(2,"world"),(4,"!")]
    
    >>> sortOn length ["jim", "creed", "pam", "michael", "dwight", "kevin"]
    ["jim","pam","creed","kevin","dwight","michael"]
    

    Performance notes

    This function minimises the projections performed, by materialising the projections in an intermediate list. For trivial projections, you should prefer using sortBy with comparing, for example:
    >>> sortBy (comparing fst) [(3, 1), (2, 2), (1, 3)]
    [(1,3),(2,2),(3,1)]
    
    Or, for the exact same API as sortOn, you can use `sortBy . comparing`:
    >>> (sortBy . comparing) fst [(3, 1), (2, 2), (1, 3)]
    [(1,3),(2,2),(3,1)]
    

  8. sortBy :: (a -> a -> Ordering) -> [a] -> [a]

    incipit-base Incipit.Base

    The sortBy function is the non-overloaded version of sort. The argument must be finite. The supplied comparison relation is supposed to be reflexive and antisymmetric, otherwise, e. g., for _ _ -> GT, the ordered list simply does not exist. The relation is also expected to be transitive: if it is not then sortBy might fail to find an ordered permutation, even if it exists.

    Examples

    >>> sortBy (\(a,_) (b,_) -> compare a b) [(2, "world"), (4, "!"), (1, "Hello")]
    [(1,"Hello"),(2,"world"),(4,"!")]
    

  9. sortOn :: Ord b => (a -> b) -> [a] -> [a]

    incipit-base Incipit.Base

    Sort a list by comparing the results of a key function applied to each element. sortOn f is equivalent to sortBy (comparing f), but has the performance advantage of only evaluating f once for each element in the input list. This is called the decorate-sort-undecorate paradigm, or Schwartzian transform. Elements are arranged from lowest to highest, keeping duplicates in the order they appeared in the input. The argument must be finite.

    Examples

    >>> sortOn fst [(2, "world"), (4, "!"), (1, "Hello")]
    [(1,"Hello"),(2,"world"),(4,"!")]
    
    >>> sortOn length ["jim", "creed", "pam", "michael", "dwight", "kevin"]
    ["jim","pam","creed","kevin","dwight","michael"]
    

    Performance notes

    This function minimises the projections performed, by materialising the projections in an intermediate list. For trivial projections, you should prefer using sortBy with comparing, for example:
    >>> sortBy (comparing fst) [(3, 1), (2, 2), (1, 3)]
    [(1,3),(2,2),(3,1)]
    
    Or, for the exact same API as sortOn, you can use `sortBy . comparing`:
    >>> (sortBy . comparing) fst [(3, 1), (2, 2), (1, 3)]
    [(1,3),(2,2),(3,1)]
    

  10. sortKeyVals :: RenderConfig -> Maybe ((KeyVals, KeyVals) -> (KeyVals, KeyVals))

    kvitable Data.KVITable.Render

    Specifies a function to sort the KeyVals (rows and columns, respectively) for the output. If no function provided, no sorting is performed. The provided KeyVals are in the order in which the Keys are declared to the KVITable; the values for each key may be in an arbitrary order. The usual expectation is that this will only sort the values for each Key, but it is allowed to re-order the Keys as well. Sorting is done *prior* to applying maxCells and maxCols limitations; this provides the unsurprising results for the user but means that this function may perform extra work to sort rows and columns that will not be shown. It is permissible to move entries from the rows to the columns and vice-versa; this function has control over the shape of the resulting table, which includes redistributing the rows and columns such that the result will violate maxCols (but not maxCells). The columns keyvals will be empty if colStackAt is Nothing.

Page 32 of many | Previous | Next