-
Notifications
You must be signed in to change notification settings - Fork 2
/
layers.cabal
144 lines (131 loc) · 5.69 KB
/
layers.cabal
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
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
name: layers
version: 1.0.0
synopsis: Modular type class machinery for monad transformer stacks.
license: BSD3
license-file: LICENSE
author: Shane O'Brien
maintainer: [email protected]
stability: Experimental
category: Control
cabal-version: >= 1.6
homepage: https://github.com/duairc/layers
bug-reports: https://github.com/duairc/layers/issues
build-type: Simple
description:
The @<https://hackage.haskell.org/package/layers layers>@ package provides
the type class machinery needed to make monads built out of
<Documentation-Layers-Glossary.html#monadtransformerstack stacks> of
<Documentation-Layers-Glossary.html#monadtransformer monad transformers>
easy to use. The type class machinery provided and the design patterns
suggested by @<https://hackage.haskell.org/package/layers layers>@ allow for
much more modularity than is possible with the existing type class machinery
and design patterns. With
@<https://hackage.haskell.org/package/layers layers>@
it is possible to use arbitrary
<Documentation-Layers-Glossary.html#monadinterface monad interfaces>
(<Documentation-Layers-Glossary.html#monadinterface monad interfaces> are
what we call the sort of type classes that you see in the
@<https://hackage.haskell.org/package/mtl mtl>@
and similar packages) with arbtirary
<Documentation-Layers-Glossary.html#monadtransformer monad transformers>
(by <Documentation-Layers-Glossary.html#monadtransformer monad transformers>
here, we are specifically to
<Documentation-Layers-Glossary.html#monadconstructor monad constructors>,
such as the ones defined in
@<https://hackage.haskell.org/package/transformers transformers>@), without
ever having to explicitly define how to lift specific
<Documentation-Layers-Glossary.html#monadinterface interfaces> through
specific <Documentation-Layers-Glossary.html#monadtransformer transformers>.
It also provides a more complete
set of <Documentation-Layers-Glossary.html#monadinterface monad interfaces>
than the @<https://hackage.haskell.org/package/mtl mtl>@, which fully solve
the problems of exceptions and exception safety (among others), while
maintaining full compatibility with all the
<Documentation-Layers-Glossary.html#monadinterface monad interfaces> from the
@<https://hackage.haskell.org/package/mtl mtl>@.
.
@<https://hackage.haskell.org/package/layers layers>@ improves upon and/or
replaces, in part or in whole, the following list of packages:
@<https://hackage.haskell.org/package/mtl mtl>@,
@<https://hackage.haskell.org/package/mmtl mmtl>@,
@<https://hackage.haskell.org/package/transformers-base transformers-base>@,
@<https://hackage.haskell.org/package/monad-control monad-control>@,
@<https://hackage.haskell.org/package/lifted-base lifted-base>@,
@<https://hackage.haskell.org/package/monad-peel monad-peel>@,
@<https://hackage.haskell.org/package/MonadCatchIO-transformers MonadCatchIO-transformers>@,
@<https://hackage.haskell.org/package/exceptions exceptions>@,
@<https://hackage.haskell.org/package/MonadCatchIO-mtl MonadCatchIO-mtl>@,
@<https://hackage.haskell.org/package/exception-transformers exception-transformers>@,
@<https://hackage.haskell.org/package/monad-abort-fd monad-abort-fd>@ and
probably more too. There have been many attempts to either improve upon or
work around the deficiencies of the existing type class machinery for
<Documentation-Layers-Glossary.html#monadtransformerstack monad transformer stacks>,
but we believe
@<https://hackage.haskell.org/package/layers layers>@ is the most complete of
any of these so far.
.
A comprehensive overview of the motivation behind
@<https://hackage.haskell.org/package/layers layers>@ and an explanation of
the design decisions taken is given in "Documentation.Layers.Overview". It
is /highly recommended/ that you read this if you are considering using this
package. A detailed glossary of the jargon used throughout the documentation
of this package is given in "Documentation.Layers.Glossary". The core type
classes used by the package are exported from "Control.Monad.Lift" (some of
these originate in
@<https://hackage.haskell.org/package/transformers transformers>@ and
@<https://hackage.haskell.org/package/mmorph mmorph>@). The rest of the
modules in this package export
<Documentation-Layers-Glossary.html#monadinterface monad interfaces>, in the
<doc-index-M.html Monad.*> hierarchy, including replacements for all of the
<Documentation-Layers-Glossary.html#monadinterface monad interfaces> of the
@<https://hackage.haskell.org/package/mtl mtl>@ package.
extra-source-files:
include/*.h
LICENSE
Library
hs-source-dirs:
src
include-dirs:
include
exposed-modules:
Documentation.Layers.Glossary
Documentation.Layers.Overview
Control.Monad.Lift
Control.Monad.Lift.Base
Control.Monad.Lift.IO
Control.Monad.Lift.Layer
Control.Monad.Lift.Top
Monad.Abort
Monad.Cont
Monad.Catch
Monad.Error
Monad.Fork
Monad.Mask
Monad.Reader
Monad.Recover
Monad.RWS
Monad.State
Monad.ST
Monad.Throw
Monad.Try
Monad.Writer
other-modules:
Control.Monad.Lift.Internal
build-depends:
base >= 4 && < 5,
mmorph >= 1.0 && < 1.2,
transformers >= 0.2 && < 0.6
ghc-options:
-Wall
if impl(ghc < 7)
cpp-options: -DINLINABLE=INLINE
if impl(ghc >= 7.2)
cpp-options: -DLANGUAGE_DefaultSignatures
if impl(ghc >= 7.2)
cpp-options: -DLANGUAGE_SafeHaskell
if impl(ghc >= 7.8)
cpp-options: -DClosedTypeFamilies
if impl(ghc >= 7.10)
cpp-options: -DOverlapPragma -DOverlappingInstances=NoImplicitParams
if impl(ghc >= 7.8)
cpp-options: -DMinimalPragma