···
2
+
maintainer: "Enrico Tassi <enrico.tassi@inria.fr>"
3
+
authors: [ "Claudio Sacerdoti Coen" "Enrico Tassi" ]
4
+
license: "LGPL-2.1-or-later"
5
+
homepage: "https://github.com/LPCIC/elpi"
6
+
doc: "https://LPCIC.github.io/elpi/"
7
+
dev-repo: "git+https://github.com/LPCIC/elpi.git"
8
+
bug-reports: "https://github.com/LPCIC/elpi/issues"
11
+
["dune" "subst"] {dev}
12
+
[make "config" "LEGACY_PARSER=1"] {elpi-option-legacy-parser:installed}
13
+
[make "build" "DUNE_OPTS=-p %{name}% -j %{jobs}%"]
14
+
[make "tests" "DUNE_OPTS=-p %{name}%" "SKIP=performance_HO" "SKIP+=performance_FO"] {with-test & os != "macos" & os-distribution != "alpine" & os-distribution != "freebsd"}
18
+
"ocaml" {>= "4.07.0" }
20
+
"ppxlib" {>= "0.12.0" }
21
+
"menhir" {>= "20211230" }
23
+
"ppx_deriving" {>= "4.3"}
24
+
"ANSITerminal" {with-test}
25
+
"cmdliner" {with-test}
27
+
"conf-time" {with-test}
28
+
"atdgen" {>= "2.9.1"}
29
+
"atdts" {>= "2.9.1"}
32
+
"elpi-option-legacy-parser"
35
+
"elpi-option-legacy-parser" {!= "1"}
37
+
synopsis: "ELPI - Embeddable λProlog Interpreter"
39
+
ELPI implements a variant of λProlog enriched with Constraint Handling Rules,
40
+
a programming language well suited to manipulate syntax trees with binders.
42
+
ELPI is designed to be embedded into larger applications written in OCaml as
43
+
an extension language. It comes with an API to drive the interpreter and
44
+
with an FFI for defining built-in predicates and data types, as well as
45
+
quotations and similar goodies that are handy to adapt the language to the host
48
+
This package provides both a command line interpreter (elpi) and a library to
49
+
be linked in other applications (eg by passing -package elpi to ocamlfind).
51
+
The ELPI programming language has the following features:
53
+
- Native support for variable binding and substitution, via an Higher Order
54
+
Abstract Syntax (HOAS) embedding of the object language. The programmer
55
+
does not need to care about technical devices to handle bound variables,
56
+
like De Bruijn indices.
58
+
- Native support for hypothetical context. When moving under a binder one can
59
+
attach to the bound variable extra information that is collected when the
60
+
variable gets out of scope. For example when writing a type-checker the
61
+
programmer needs not to care about managing the typing context.
63
+
- Native support for higher order unification variables, again via HOAS.
64
+
Unification variables of the meta-language (λProlog) can be reused to
65
+
represent the unification variables of the object language. The programmer
66
+
does not need to care about the unification-variable assignment map and
67
+
cannot assign to a unification variable a term containing variables out of
68
+
scope, or build a circular assignment.
70
+
- Native support for syntactic constraints and their meta-level handling rules.
71
+
The generative semantics of Prolog can be disabled by turning a goal into a
72
+
syntactic constraint (suspended goal). A syntactic constraint is resumed as
73
+
soon as relevant variables gets assigned. Syntactic constraints can be
74
+
manipulated by constraint handling rules (CHR).
76
+
- Native support for backtracking. To ease implementation of search.
78
+
- The constraint store is extensible. The host application can declare
79
+
non-syntactic constraints and use custom constraint solvers to check their
82
+
- Clauses are graftable. The user is free to extend an existing program by
83
+
inserting/removing clauses, both at runtime (using implication) and at
84
+
"compilation" time by accumulating files.
86
+
ELPI is free software released under the terms of LGPL 2.1 or above."""
89
+
"https://github.com/LPCIC/elpi/releases/download/v1.16.1/elpi-1.16.1.tbz"
91
+
"sha256=7fe71cd548336aed3dcbbf37b00cf3372466cdcb55f10e8d0b39181f6e2c898b"
92
+
"sha512=6d65b7be2083bec93f972b8291feb24509d5c83e0208101438b8f6099c398d310f8e3e4a3ab393280f40f5731f28e0cfdaa2a4563725092766e1d232b7d07f2c"
95
+
x-commit-hash: "6ca6012a6bb38a7e1bd3c136f7184d98b17eb7cc"