cardano-api:internal
Safe HaskellNone
LanguageHaskell2010

Cardano.Api.Utils

Description

Internal utils for the other Api modules

Synopsis

Documentation

(?!) :: Maybe a -> e -> Either e a Source #

(?!.) :: Either e a -> (e -> e') -> Either e' a Source #

failEitherWith :: MonadFail m => (e -> String) -> Either e a -> m a Source #

note :: MonadFail m => String -> Maybe a -> m a Source #

runParsecParser :: Parser a -> Text -> Parser a Source #

textShow :: Show a => a -> Text Source #

CLI option parsing

unsafeBoundedRational :: (HasCallStack, Typeable r, BoundedRational r) => Rational -> r Source #

Convert Rational to a bounded rational. Throw an exception when the rational is out of bounds.