package datalog

  1. Overview
  2. Docs
An in-memory datalog implementation for OCaml

Install

Dune Dependency

Authors

Maintainers

Sources

datalog-0.7.tbz
sha256=13ca520bddf4f0c44d1468bc89347be72ec543be58fff29469a0da24956be541
sha512=25d6e9cb5abe8aa1110730d884abb9e51ae78bf681b3f21709efa32359b9cbdd97d9076761c91562580c090cbce12ce159c97533ae5d9d427c24cb329e950793

doc/datalog.unix/Datalog_unix/Make/argument-1-TD/Rewriting/index.html

Module TD.Rewriting

type rule = T.t * T.t
type t

A rewriting system. It is basically a mutable set of rewrite rules.

val create : unit -> t

New rewriting system

val copy : t -> t

Copy the rewriting system

val add : t -> rule -> unit

Add a rule to the system

val add_list : t -> rule list -> unit
val to_list : t -> rule list

List of rules

val rewrite_root : t -> T.t -> T.t

rewrite the term, but only its root. Subterms are not rewritten at all.

val rewrite : t -> T.t -> T.t

Normalize the term recursively. The returned type cannot be rewritten any further, assuming the rewriting system is terminating

OCaml

Innovation. Community. Security.