package path_glob

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

Provides a datatype for representing propositional formulas and evaluation, iteration and map functions.

type 'a t =
  1. | And of 'a t list
  2. | Or of 'a t list
  3. | Not of 'a t
  4. | Atom of 'a
  5. | True
  6. | False

Public type for generic propositional formulas. An empty conjunction And[] is true and an empty disjunction Or[] is false.

val eval : ('a -> bool) -> 'a t -> bool

eval g f evaluates the formula f using the values returned by g for the atoms.

val iter : ('a -> unit) -> 'a t -> unit

iter g f calls g over every atom of f.

val map : ('a -> 'b) -> 'a t -> 'b t

map g f replaces every atom of f by its image by g.