Remove global variables from the program by translating
them into constructors, making proof generation easier.
Does not support primitive-valued globals.
Remove global variables from the program by translating
them into functions with no arguments.
This requires type information, so it is done after type checking.
Primitives are translated into functions with a primitive output.
When a globally-bound primitive value is used in the actions of a rule,
we add a new variable to the query bound to the primitive value.
A container sort’s rebuild-primitive names, carried on its (sort …) as the
:internal-container-rebuild annotation. Everything else needed to register
the primitives is recovered from proof_state at register time.
The program-global proof constructor names, recorded on the Proof sort as
the :internal-proof-names annotation (the Proof datatype name is the
sort’s own name).
Facts are the left-hand side of a [Command::Rule].
They represent a part of a database query.
Facts can be expressions or equality constraints between expressions.
The mode of printing a function. The default mode prints the function in a user-friendly way and
has an unreliable interface.
The CSV mode prints the function in the CSV format.
A parsed S-expression. Atoms borrow from the input; macros may also construct
atoms with owned strings. Spans own their source and can outlive the input.