package forester

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Module Forester_core.QuerySource

Relation symbols

Sourcemodule Rel : sig ... end
Sourcetype rel = Rel.t

Query modifiers

Sourcetype polarity =
  1. | Incoming
  2. | Outgoing

Determines whether we are searching for edges into or out of the supplied vertex.

Sourcetype mode =
  1. | Edges
  2. | Paths

Determines whether we are querying a relation or its reflexive-transitive closure.

Query expression

Sourcetype dbix = int

De Bruijn indices for bound variables, counting outward from the innermost binder.

Sourcetype name = Symbol.t

Globally unique symbols for free variables.

Sourcetype lnvar =
  1. | F of name
  2. | B of dbix

A variable in 'locally nameless' representation is either free or bound.

Sourcetype 'var addr_expr =
  1. | Addr of Base.addr
  2. | Var of 'var

An address expression can be concrete, or it can be a variable.

Sourcetype 'a binder = {
  1. body : 'a;
}

Don't use the constructor/destructor unless you know what you are doing!

Sourcetype 'var expr =
  1. | Rel of mode * polarity * Rel.t * 'var addr_expr
  2. | Isect of 'var expr list
  3. | Union of 'var expr list
  4. | Complement of 'var expr
  5. | Union_fam of 'var expr * 'var expr binder
  6. | Isect_fam of 'var expr * 'var expr binder
Sourceval distill_expr : lnvar expr -> dbix expr
Sourceexception Distill of name

Locally nameless operations and smart constructors

Sourceval rel : mode -> polarity -> rel -> 'var addr_expr -> 'var expr
Sourceval isect : 'var expr list -> 'var expr
Sourceval union : 'var expr list -> 'var expr
Sourceval union_fam : lnvar expr -> Symbol.t -> lnvar expr -> lnvar expr
Sourceval isect_fam : lnvar expr -> Symbol.t -> lnvar expr -> lnvar expr
Sourceval isect_fam_rel : lnvar expr -> mode -> polarity -> rel -> lnvar expr
Sourceval union_fam_rel : lnvar expr -> mode -> polarity -> rel -> lnvar expr
Sourceval references : lnvar addr_expr -> lnvar expr
Sourceval context : lnvar addr_expr -> lnvar expr
Sourceval contributions : lnvar addr_expr -> lnvar expr
Sourceval hereditary_contributors : lnvar addr_expr -> lnvar expr