package datalog
An in-memory datalog implementation for OCaml
Install
Dune Dependency
Authors
Maintainers
Sources
datalog-0.7.tbz
sha256=13ca520bddf4f0c44d1468bc89347be72ec543be58fff29469a0da24956be541
sha512=25d6e9cb5abe8aa1110730d884abb9e51ae78bf681b3f21709efa32359b9cbdd97d9076761c91562580c090cbce12ce159c97533ae5d9d427c24cb329e950793
doc/src/datalog.top_down/AST.ml.html
Source file AST.ml
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46
(* this file is part of datalog. See README for the license *) (** {1 AST for TopDown terms} *) type term = | Var of string | Apply of string * term list | Int of int type aggregate = { ag_left : term; ag_constructor : string; ag_var : string; ag_guard : term; } (* aggregate: ag_left = ag_constructor set where set is the set of bindings to ag_var that satisfy ag_guard *) type literal = | LitPos of term | LitNeg of term | LitAggr of aggregate type clause = term * literal list type file = clause list exception ParseError of string let loc_to_str pos = Printf.sprintf "line %d, column %d" pos.Lexing.pos_lnum (pos.Lexing.pos_cnum - pos.Lexing.pos_bol) let print_error ?(out=stderr) msg lexbuf = let start = Lexing.lexeme_start_p lexbuf in let stop = Lexing.lexeme_end_p lexbuf in Printf.fprintf out "parse error between %s and %s: %s\n" (loc_to_str start) (loc_to_str stop) msg let error_to_string msg lexbuf = let start = Lexing.lexeme_start_p lexbuf in let stop = Lexing.lexeme_end_p lexbuf in Printf.sprintf "parse error between %s and %s: %s\n" (loc_to_str start) (loc_to_str stop) msg
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>