on a84e6cf help sign in
streamly/src/Streamly/Internal/BaseCompat.hs
27 lines 597 B history raw
1-- |
2-- Module : Streamly.Internal.BaseCompat
3-- License : BSD3
4-- Maintainer : streamly@composewell.com
5-- Stability : experimental
6-- Portability : GHC
7--
8-- Compatibility functions for "base" package.
9--
10module Streamly.Internal.BaseCompat
11 (
12 (#.)
13 , errorWithoutStackTrace
14 )
15where
17import Data.Coerce (Coercible, coerce)
19{-# INLINE (#.) #-}
20(#.) :: Coercible b c => (b -> c) -> (a -> b) -> (a -> c)
21(#.) _f = coerce
23#if !(MIN_VERSION_base(4,9,0))
24{-# NOINLINE errorWithoutStackTrace #-}
25errorWithoutStackTrace :: String -> a
26errorWithoutStackTrace = error
27#endif