-
Notifications
You must be signed in to change notification settings - Fork 0
/
shapely-data.cabal
118 lines (100 loc) · 3.9 KB
/
shapely-data.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
Name: shapely-data
Version: 0.1
tested-with: GHC == 7.6.3
Synopsis: Generics using (,) and Either, with algebraic operations and typed conversions
Description:
@shapely-data@ is a library for working with algebraic datatypes in a
simple generic form made up of haskell's primitive product, sum and unit
types: @(,)@, @Either@, and @()@, providing something like light-weight
Structural Typing.
.
The library was not designed to facilitate generic traversals or
abstraction over different recursion schemes, but rather to (from most to
least important)
.
- Provide a good story for @(,)@ & @Either@ as a /lingua franca/ generic
representation that other library writers can use without dependencies,
encouraging abstractions in terms of products and sums
.
- Support algebraic operations on ADTs, making types composable
.
- Support powerful, typed conversions between 'Shapely' types
.
/Influences/
.
I've taken lots of inspiration, code, names, ideas, and type-level
programming techniques from, in particular
.
- Oleg Kiselyov's "HList" work
.
- Edward Kmett's "categories" package
.
- Chris Taylor's "Algebra of Algebraic Datatypes" series at
<http://chris-taylor.github.io/blog/2013/02/10/the-algebra-of-algebraic-data-types/>
.
/Issues and Limitations:/
.
- 'massage' does not support mutually-recursive types and other more
complicated recursion schemes, nor type application.
.
- While all classes except 'Shapely' are considered closed, we don't do any
tricks to enforce that in the API yet.
.
- In fancier functions that use type equality (e.g. 'coerce'), types need to
be unambiguous so type signatures are sometimes required.
.
- type errors, especially in 'massage' and 'coerce', can be cryptic
.
- TH deriving hasn't been considered for fancier types like GADTs,
existential types, etc. some of which may have sensible Shapely instances
.
- Performance hasn't been tested at all yet.
Homepage: http://github.com/jberryman/shapely-data
License: BSD3
License-file: LICENSE
Author: Brandon Simmons
Maintainer: brandon.m.simmons@gmail.com
Category: Data, Generics
Build-type: Simple
Cabal-version: >= 1.8
Extra-source-files: README.md
, examples/Generics.hs
source-repository head
type: git
location: https://github.com/jberryman/shapely-data.git
branch: master
Library
hs-source-dirs: src
Exposed-modules: Data.Shapely
, Data.Shapely.Normal
, Data.Shapely.Spine
, Data.Shapely.Normal.TypeIndexed
Other-modules: Data.Shapely.Category
, Data.Shapely.Bool
, Data.Shapely.Classes
, Data.Shapely.Normal.Classes
, Data.Shapely.Normal.Exponentiation
, Data.Shapely.Normal.Coercible
, Data.Shapely.Normal.Massageable
, Data.Shapely.TH
, Data.Shapely.Utilities
ghc-options: -Wall
Build-depends: base <5
, template-haskell >= 2 && < 3
, tagged
, proxy-kindness == 0.1
Extensions: TemplateHaskell
test-suite test
type: exitcode-stdio-1.0
hs-source-dirs: test, src
main-is: Main.hs
-- ghc-options: -fhpc
Build-depends: base <5
, template-haskell >= 2 && < 3
, tagged
, proxy-kindness == 0.1
-- new:
, QuickCheck >= 2, containers
-- is this right?
, shapely-data
Extensions: TemplateHaskell