flix

0.80.0

Datalog

Abstract syntax tree of Datalog programs.

enum DatalogSource

Datalog(facts, rules) is a Datalog program where facts and rules are the facts and rules of the program, respectively.

Model(factsMap) is a model mapping RelSym the their IDB/facts.

Join(p1, p2) is the combination of Datalog programs p1 and p2.

Provenance(rules, model) is a Datalog model where model is a map from computed facts to annotations of the form (depth, ruleUsed) and rules are the rules used during the computation of model.

Instances

PredSymsOf, SubstitutePredSym, ToString

Enums

BodyPredicateRepresents a predicate in the body of a rule: an atom, a functional, or a guard.
BodyTermRepresents a term in a body atom: a wildcard, a variable, or a literal.
ConstraintRepresents a Datalog fact or rule, consisting of a head predicate and a body.
FixityRepresents whether a body atom is `Fixed` (evaluated only against the full relation) or `Loose`.
HeadPredicateRepresents the head atom of a Datalog constraint.
HeadTermRepresents a term in a head atom: a variable, a literal, or a function application.
PolarityRepresents whether a body atom is positive or negated.
VarSymRepresents a variable symbol in a Datalog constraint.