]> Git — Sourcephile - haskell/symantic-parser.git/blob - symantic-parser.cabal
grammar: rename Parser.{Haskell => Grammar.Pure}
[haskell/symantic-parser.git] / symantic-parser.cabal
1 cabal-version: 2.4
2 name: symantic-parser
3 version: 0.0.0.20210102
4 synopsis: Parser combinators statically optimized and staged via typed meta-programming
5 description:
6 This is a work-in-progress experimental library to generate parsers,
7 leveraging Tagless-Final interpreters and Typed Template Haskell staging.
8 .
9 This is an alternative but less powerful/reviewed
10 implementation of [ParsleyHaskell](https://github.com/J-mie6/ParsleyHaskell).
11 See the paper by Jamie Willis, Nicolas Wu, and Matthew
12 Pickering, admirably well presented at ICFP-2020: [Staged
13 Selective Parser
14 Combinators](https://icfp20.sigplan.org/details/icfp-2020-papers/20/Staged-Selective-Parser-Combinators).
15 license: GPL-3.0-or-later
16 author: Julien Moutinho <julm+symantic-parser@sourcephile.fr>
17 maintainer: Julien Moutinho <julm+symantic-parser@sourcephile.fr>
18 bug-reports: Julien Moutinho <julm+symantic-parser@sourcephile.fr>
19 copyright: Julien Moutinho <julm+symantic-parser@sourcephile.fr>
20 stability: experimental
21 category: Parsing
22 extra-doc-files:
23 ChangeLog.md
24 ReadMe.md
25 ToDo.md
26 extra-source-files:
27 .envrc
28 Makefile
29 cabal.project
30 default.nix
31 flake.nix
32 shell.nix
33 test/Golden/**/*.dump
34 test/Golden/**/*.txt
35 extra-tmp-files:
36 build-type: Simple
37 tested-with: GHC==9.0.0
38
39 source-repository head
40 type: git
41 location: git://git.sourcephile.fr/haskell/symantic-parser
42
43 flag dump-core
44 description: Dump GHC's Core in HTML
45 manual: True
46 default: False
47
48 flag dump-splices
49 description: Dump code generated by Template Haskell
50 manual: True
51 default: False
52
53 common boilerplate
54 default-language: Haskell2010
55 default-extensions:
56 BangPatterns,
57 DataKinds,
58 FlexibleContexts,
59 FlexibleInstances,
60 GADTs,
61 GeneralizedNewtypeDeriving,
62 LambdaCase,
63 MultiParamTypeClasses,
64 NamedFieldPuns,
65 NoImplicitPrelude,
66 RankNTypes,
67 RecordWildCards,
68 ScopedTypeVariables,
69 TypeApplications,
70 TypeFamilies,
71 TypeOperators
72 ghc-options:
73 -Wall
74 -Wincomplete-uni-patterns
75 -Wincomplete-record-updates
76 -fhide-source-paths
77 -freverse-errors
78
79 library
80 import: boilerplate
81 hs-source-dirs: src
82 exposed-modules:
83 Symantic.Univariant.Letable
84 Symantic.Univariant.Trans
85 Symantic.Parser
86 Symantic.Parser.Grammar
87 Symantic.Parser.Grammar.Combinators
88 Symantic.Parser.Grammar.Dump
89 Symantic.Parser.Grammar.Fixity
90 Symantic.Parser.Grammar.ObserveSharing
91 Symantic.Parser.Grammar.Optimize
92 Symantic.Parser.Grammar.Pure
93 Symantic.Parser.Grammar.Write
94 Symantic.Parser.Machine
95 Symantic.Parser.Machine.Dump
96 Symantic.Parser.Machine.Generate
97 Symantic.Parser.Machine.Input
98 Symantic.Parser.Machine.Instructions
99 build-depends:
100 base >=4.10 && <5,
101 array,
102 bytestring,
103 containers,
104 ghc-prim,
105 hashable,
106 template-haskell >= 2.16,
107 text,
108 transformers,
109 unordered-containers
110
111 test-suite symantic-parser-test
112 import: boilerplate
113 type: exitcode-stdio-1.0
114 hs-source-dirs: test
115 main-is: Main.hs
116 other-modules:
117 Golden
118 Golden.Grammar
119 -- Golden.Utils
120 -- Golden.Parsers
121 -- HUnit
122 -- QuickCheck
123 default-extensions:
124 ViewPatterns
125 ghc-options:
126 build-depends:
127 symantic-parser,
128 base >= 4.10 && < 5,
129 bytestring >= 0.10,
130 containers >= 0.5,
131 deepseq >= 1.4,
132 directory >= 1.3,
133 filepath >= 1.4,
134 hashable >= 1.2.6,
135 process >= 1.6,
136 strict >= 0.4,
137 tasty >= 0.11,
138 tasty-golden >= 2.3,
139 -- tasty-hunit,
140 template-haskell >= 2.16,
141 -- temporary >= 1.3,
142 text >= 1.2,
143 -- time >= 1.9,
144 transformers >= 0.4,
145 -- QuickCheck >= 2.0,
146 -- tasty-quickcheck,
147 unix >= 2.7,
148 unordered-containers
149 if flag(dump-core)
150 build-depends: dump-core
151 ghc-options: -fplugin=DumpCore
152 if flag(dump-splices)
153 ghc-options:
154 -ddump-splices
155 -ddump-to-file