Releases: LPCIC/elpi
Releases · LPCIC/elpi
v1.9.0
CHANGES:
-
Typing:
typeabbrevdeclarations are now taken into account and unfolded
by the compiler. The type checker refolds abbreviations
when printing error messages with the following caveat: when two type
abbreviations can be refolded the last declared one wins.
-
Compiler:
@macroare no more accepted in types, sincetypeabbrevprovides the
same functionality.- fix clash between builtin names and type names
accumulateis idempotent: accumulating the same file a second time
has no effect.
-
FFI:
- built in predicate are allowed to not assign (not produce a value) for
output and input-output arguments. - input-output arguments are forced to be
Conversion.tof type'a ioarg,
and recommended to wrap any nested type not able to represent variables
inioarg. Egint optionshould beint ioarg option ioarg. In this
way one can safely call these builtins with non-ground terms, such as
some _, for example to assert the result is notnonebut without
providing a ground term such assome 3. MLDatadeclarations forOpaqueDataare no more named using a macro
but rather using a type abbreviation. This can break user code. The fix
is to substitutie@myopaquetypewithmyopaquetypeeverywhere.
- built in predicate are allowed to not assign (not produce a value) for
-
Stdlib:
diagnosticdata type to be used as anioargfor builtins that can fail
with a relevant error message. On the ML side one can usedElpi.Builtin.mkOK
andElpi.Builtin.mkERROR "msg"to build its values.std.assert-ok!,std.forall-ok,std.do-ok!,std.lift-okand
std.while-ok-do!commodity predicates.- All operators for
calc(infix_ is _) now come with a type declaration.
v1.8.0
CHANGES:
-
Bugfix:
shorten foo.{ bar }.whenfoo.baris a builtin used to be miscompiled.elpi-typechecker.elpinow correclty stops printing warnings after it
printed 10 (used to stop after he processed 10, that may not be the same
thing, since some warnings are suppressed).
-
Parser:
- Interpret
-2(with no space) as the negative2not as the constant-2.
This wayX is 3 - 2andY is 3 + -2are both valid.
- Interpret
-
FFI:
OpaqueDatanow requires a ternary comparison, not just equality.
-
Stdlib:
- new data type
cmpfor ternary comparison. std.setandstd.mapnow based on ternary comparison.
- new data type
-
Builtin:
cmp_termgiving an order on ground terms.ground_termto check if a term is ground.
v1.7.0
CHANGES:
-
Parser:
- Tolerate trailing
,in lists, eg[1,2,3,]is now parsed as[1,2,3]. - Error if the input of
Parse.goal_from_stringcontains extra tokens - Binary conjunction
&is now turned on the fly into the nary one,.
- Tolerate trailing
-
Bugfix:
- Nasty bug in pruning during higher order unification, see #36.
Discardis now considered a stack term, and is turned into an
unification variable on heapification.API.RawData.looknow expandsUVarcorrectly
-
Stdlib:
setandmapfor arbitrary terms equipped with an order relation.
Based on the code of OCaml'sMapandSetlibrary.- New API
map.removefor maps on builtin data.
-
FFI:
- New
ContextualConversionmodule andctx_readbacktype. In an FFI call
one can specify a readback for the hypothetical context that is run once
and its output is give to the ML code instead of the "raw" constraints and
hyp list.
- New
-
API:
- Commodity functions in
Elpi.Builtinto export as built-in
OCaml'sSet.SandMap.Sinterfaces (the output ofSet.Make
andMap.Make). All data is limited to be a closed term. Constants.andc2was removedFlexibleData.Elpi.maketakes no~lvlargument (it is always0)RawData.viewno more containsDiscardsince it is not an heap term
- Commodity functions in
-
Misc:
- Pretty printer for unification variable made re-entrant w.r.t. calls to the
CHR engine (used to lose the mapping between heap cells and names) - Pretty printer for solution abstracted over a context (part of the solution). In this
way the result can be printed correctly even if the runtime has been destroyed. - Default paths for finding
.elpifiles fixed after the switch to dune - A few more tests regarding unification, data structures and performance
- Pretty printer for unification variable made re-entrant w.r.t. calls to the
v1.6.0
CHANGES:
-
Builtin:
same_term(infix==) for Prolog's non-logical comparison (without
instantiation).setandmap A(Aonly allowed to be a closed term) on
string,intandlockeys.
-
Compiler:
- provide line number on error about duplicate mode declaration
- elpi-checker is faster and bails out after 10 seconds
-
FFI:
- allow
AlgebraicDatadeclarations to mixMandMSconstructors Conversion.tfor closed terms (no unification variable and no variables
bound by the program)
- allow
-
Tests:
- typecheck all tests and measure type checking time
v1.5.2
v1.5.1
v1.5.0
CHANGES:
Elpi 1.5 requires OCaml 4.04 or newer
-
REPL:
- type errors are considered fatal, pass
-no-tcto skip type checking. - use dune subst in order to implement
-versionflag to the command line
utility.
- type errors are considered fatal, pass
-
Runtime:
- reset unification variables names map at each execution. This makes
the names of variable printed in a reproducible way across executions.
- reset unification variables names map at each execution. This makes
-
FFI:
readbackis now as powerful asembedand can generate extra goals. The
two types are now dual.
ELPI 1.4.1
Minor fixup to error locations
ELPI 1.4.0
Build based on dune and library wrapped
Elpi 1.3.1
Makefile fixup for the opam archive