Hoogle Search

Within LTS Haskell 24.50 (ghc-9.10.3)

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

  1. showList :: Show a => [a] -> ShowS

    clash-prelude Clash.HaskellPrelude

    The method showList is provided to allow the programmer to give a specialised way of showing lists of values. For example, this is used by the predefined Show instance of the Char type, where values of type String should be shown in double quotes, rather than between square brackets.

  2. showParen :: Bool -> ShowS -> ShowS

    clash-prelude Clash.HaskellPrelude

    utility function that surrounds the inner show function with parentheses when the Bool parameter is True.

  3. showString :: String -> ShowS

    clash-prelude Clash.HaskellPrelude

    utility function converting a String to a show function that simply prepends the string unchanged.

  4. shows :: Show a => a -> ShowS

    clash-prelude Clash.HaskellPrelude

    equivalent to showsPrec with a precedence of 0.

  5. showsPrec :: Show a => Int -> a -> ShowS

    clash-prelude Clash.HaskellPrelude

    Convert a value to a readable String. showsPrec should satisfy the law

    showsPrec d x r ++ s  ==  showsPrec d x (r ++ s)
    
    Derived instances of Read and Show satisfy the following: That is, readsPrec parses the string produced by showsPrec, and delivers the value that showsPrec started with.

  6. showBNat :: forall (n :: Nat) . BNat n -> String

    clash-prelude Clash.Promoted.Nat

    Show a base-2 encoded natural as a binary literal NB: The LSB is shown as the right-most bit

    >>> d789
    d789
    
    >>> toBNat d789
    b789
    
    >>> showBNat (toBNat d789)
    "0b1100010101"
    
    >>> 0b1100010101 :: Integer
    789
    

  7. showListX :: ShowX a => [a] -> ShowS

    clash-prelude Clash.XException

    Like showList, but values that normally throw an XException are converted to undefined, instead of error'ing out with an exception.

  8. showX :: ShowX a => a -> String

    clash-prelude Clash.XException

    Like show, but values that normally throw an XException are converted to undefined, instead of error'ing out with an exception.

  9. showsPrecX :: ShowX a => Int -> a -> ShowS

    clash-prelude Clash.XException

    Like showsPrec, but values that normally throw an XException are converted to undefined, instead of error'ing out with an exception.

  10. showsPrecXWith :: (Int -> a -> ShowS) -> Int -> a -> ShowS

    clash-prelude Clash.XException

    Use when you want to create a ShowX instance where:

    • There is no Generic instance for your data type
    • The Generic derived ShowX method would traverse into the (hidden) implementation details of your data type, and you just want to show the entire value as undefined.
    Can be used like:
    data T = ...
    
    instance Show T where ...
    
    instance ShowX T where
    showsPrecX = showsPrecXWith showsPrec
    

Page 144 of many | Previous | Next