Not sure whether this is a real bug, but I would like to define a
self-contained program, i.e., without relying on the ELPI standard library.
I would like to redefine the bool type with its constructors.
The file looks like:
% main.elpi
kind bool type.
type tt bool. % The error is at this line
type ff bool.
However, when I execute the command elpi main.elpi -test, I get the
following error:
Incompatible provenance for symbol ff: Ast.Structured.Elpi !=
(Ast.Structured.OCaml Ast.Structured.Builtin {variant = 1})
Is this expected, or should the compiler understand that adding
tt to bool is a no-op, since tt already exists as
a constructor of bool in the standard library?
Moreover, what I find weird is that I can create type tt int -> bool without warnings
Not sure whether this is a real bug, but I would like to define a
self-contained program, i.e., without relying on the ELPI standard library.
I would like to redefine the
booltype with its constructors.The file looks like:
However, when I execute the command
elpi main.elpi -test, I get thefollowing error:
Is this expected, or should the compiler understand that adding
tttoboolis a no-op, sincettalready exists asa constructor of
boolin the standard library?Moreover, what I find weird is that I can create
type tt int -> boolwithout warnings