]> Git — Sourcephile - haskell/symantic-base.git/blob - symantic-base.cabal
build: update nix input `nixpkgs`
[haskell/symantic-base.git] / symantic-base.cabal
1 cabal-version: 3.0
2 name: symantic-base
3 maintainer: mailto:~julm/symantic-base@todo.code.sourcephile.fr
4 bug-reports: https://todo.code.sourcephile.fr/~julm/symantic-base
5 homepage: https://git.code.sourcephile.fr/~julm/symantic-base
6 author: Julien Moutinho <julm+symantic-base@sourcephile.fr>
7 copyright: Julien Moutinho <julm+symantic-base@sourcephile.fr>
8 license: AGPL-3.0-or-later
9 license-file: LICENSES/AGPL-3.0-or-later.txt
10 -- PVP: +-+------- breaking API changes
11 -- | | +----- non-breaking API additions
12 -- | | | +--- code changes with no API change
13 version: 0.4.0.20211106
14 stability: experimental
15 category: Data Structures
16 synopsis: Basic symantic combinators for Embedded Domain-Specific Languages (EDSL)
17 description:
18 This is a work-in-progress collection of basic tagless-final combinators,
19 along with some advanced utilities to exploit them.
20
21 * @Symantic.Classes@
22 gathers commonly used tagless-final combinators
23 (the syntax part of symantics).
24 * @Symantic.Data@ interprets combinators as data constructors
25 enabling to pattern-match on combinators while keeping their extensibility.
26 * @Symantic.Derive@
27 to give a default value to combinators which avoids boilerplate code
28 when implementing combinators for an interpreter is factorizable.
29 * @Symantic.SharingObserver@
30 interprets combinators to observe @let@ definitions at the host language level (Haskell),
31 effectively turning infinite values into finite ones,
32 which is useful for example to inspect and optimize recursive grammars.
33 Inspired by Andy Gill's [Type-safe observable sharing in Haskell](https://doi.org/10.1145/1596638.1596653).
34 For an example, see [symantic-parser](https://hackage.haskell.org/package/symantic-parser).
35 * @Symantic.Reify@
36 enables the lifting to any interpreter
37 of any Haskell functions taking as arguments
38 only polymorphic types (possibly constrained)
39 or functions using such types.
40 Inspired by Oleg Kiselyov's [TDPE.hs](http://okmij.org/ftp/tagless-final/course/TDPE.hs).
41 * @Symantic.Viewer@
42 interprets combinators as human-readable text.
43 * @Symantic.ADT@
44 enables to derive reciprocal functions between
45 algebraic data type constructors and @Either@s of tuples.
46 * @Symantic.CurryN@
47 gathers utilities for currying or uncurrying tuples
48 of size greater or equal to two.
49 * @Symantic.Fixity@
50 gathers utilities for parsing or viewing
51 infix, prefix and postfix combinators.
52 build-type: Simple
53 tested-with: GHC==8.10.4
54 extra-doc-files:
55 ChangeLog.md
56 extra-source-files:
57 cabal.project
58 .envrc
59 flake.lock
60 flake.nix
61 Makefile
62 extra-tmp-files:
63
64 source-repository head
65 type: git
66 location: https://git.code.sourcephile.fr/~julm/symantic-base
67
68 library
69 hs-source-dirs: src
70 exposed-modules:
71 Symantic
72 Symantic.ADT
73 Symantic.Classes
74 Symantic.CurryN
75 Symantic.Data
76 Symantic.Derive
77 Symantic.Fixity
78 Symantic.Optimize
79 Symantic.Reify
80 Symantic.SharingObserver
81 Symantic.Viewer
82 default-language: Haskell2010
83 default-extensions:
84 DefaultSignatures
85 FlexibleContexts
86 FlexibleInstances
87 GeneralizedNewtypeDeriving
88 LambdaCase
89 MultiParamTypeClasses
90 NamedFieldPuns
91 NoImplicitPrelude
92 RecordWildCards
93 ScopedTypeVariables
94 TupleSections
95 TypeApplications
96 TypeFamilies
97 TypeOperators
98 ghc-options:
99 -Wall
100 -Wincomplete-uni-patterns
101 -Wincomplete-record-updates
102 -Wpartial-fields
103 -fprint-potential-instances
104 build-depends:
105 base >= 4.10 && < 5,
106 containers,
107 hashable,
108 template-haskell,
109 transformers,
110 unordered-containers