Newer
Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
{-# LANGUAGE PackageImports #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE PolyKinds #-}
module Quasar.Prelude
( module BasePrelude,
module Quasar.PreludeExtras,
(>=>),
(<=<),
Control.Applicative.liftA2,
Control.Exception.throwIO,
Control.Monad.forever,
Control.Monad.unless,
Control.Monad.void,
Control.Monad.when,
Control.Monad.forM,
Control.Monad.forM_,
Control.Monad.join,
Data.Void.Void,
Hashable.Hashable,
GHC.Generics.Generic,
MonadIO,
liftIO,
Maybe.catMaybes,
Maybe.fromMaybe,
Maybe.listToMaybe,
Maybe.maybeToList,
error,
errorWithoutStackTrace,
head,
last,
read,
trace,
traceId,
traceShow,
traceShowId,
traceM,
traceShowM,
traceIO,
traceShowIO,
traceShowIdIO,
undefined,
)
where
import "base" Prelude as BasePrelude hiding
( error,
errorWithoutStackTrace,
head,
last,
read,
undefined,
)
import qualified "base" Prelude as P
import Quasar.PreludeExtras
import qualified Control.Applicative
import qualified Control.Exception
import qualified Control.Monad
import qualified Data.Void
import Control.Monad ((>=>), (<=<))
import Control.Monad.IO.Class (MonadIO, liftIO)
import qualified Data.Hashable as Hashable
import qualified Data.Maybe as Maybe
import qualified Debug.Trace as Trace
import qualified GHC.Generics
import qualified GHC.Stack.Types
import qualified GHC.Types
{-# DEPRECATED head "Partial Function." #-}
head :: [a] -> a
head = P.head
{-# DEPRECATED last "Partial Function." #-}
last :: [a] -> a
last = P.last
{-# DEPRECATED read "Partial Function." #-}
read :: Read a => String -> a
read = P.read
{-# DEPRECATED error "Undefined." #-}
error :: forall (r :: GHC.Types.RuntimeRep). forall (a :: GHC.Types.TYPE r). GHC.Stack.Types.HasCallStack => String -> a
error = P.error
{-# DEPRECATED errorWithoutStackTrace "Undefined." #-}
errorWithoutStackTrace :: String -> a
errorWithoutStackTrace = P.errorWithoutStackTrace
{-# DEPRECATED undefined "Undefined." #-}
undefined :: forall (r :: GHC.Types.RuntimeRep). forall (a :: GHC.Types.TYPE r). GHC.Stack.Types.HasCallStack => a
undefined = P.undefined
{-# DEPRECATED trace "Trace." #-}
trace :: String -> a -> a
trace = Trace.trace
{-# DEPRECATED traceId "Trace." #-}
traceId :: String -> String
traceId = Trace.traceId
{-# DEPRECATED traceShow "Trace." #-}
traceShow :: Show a => a -> b -> b
traceShow = Trace.traceShow
{-# DEPRECATED traceShowId "Trace." #-}
traceShowId :: Show a => a -> a
traceShowId = Trace.traceShowId
{-# DEPRECATED traceM "Trace." #-}
traceM :: Applicative m => String -> m ()
traceM = Trace.traceM
{-# DEPRECATED traceShowM "Trace." #-}
traceShowM :: (Show a, Applicative m) => a -> m ()
traceShowM = Trace.traceShowM
{-# DEPRECATED traceIO "Trace." #-}
traceIO :: Control.Monad.IO.Class.MonadIO m => String -> m ()
traceIO = Control.Monad.IO.Class.liftIO . Trace.traceIO
{-# DEPRECATED traceShowIO "Trace." #-}
traceShowIO :: (Control.Monad.IO.Class.MonadIO m, Show a) => a -> m ()
traceShowIO = traceIO . show
{-# DEPRECATED traceShowIdIO "Trace." #-}
traceShowIdIO :: (Control.Monad.IO.Class.MonadIO m, Show a) => a -> m a
traceShowIdIO a = traceShowIO a >> pure a