package elpi

  1. Overview
  2. Docs
val program : elpi:Setup.elpi -> ?print_accumulated_files:bool -> string list -> Ast.program

program file_list parses a list of files, Raises Failure if the file does not exist.

val program_from_stream : elpi:Setup.elpi -> ?print_accumulated_files:bool -> Ast.Loc.t -> char Stream.t -> Ast.program
val goal : Ast.Loc.t -> string -> Ast.query

goal file_list parses the query, Raises Failure if the file does not exist.

val goal_from_stream : Ast.Loc.t -> char Stream.t -> Ast.query
val resolve_file : ?cwd:string -> file:string -> unit -> string

resolve f computes the full path of f as the parser would do (also) for files recursively accumulated. Raises Failure if the file does not exist.

val std_resolver : ?cwd:string -> paths:string list -> unit -> ?cwd:string -> file:string -> unit -> string

std_resolver cwd paths () returns a resolver function that looks in cwd and paths (relative to cwd, or absolute)

exception ParseError of Ast.Loc.t * string
OCaml

Innovation. Community. Security.