package dolmen
A parser library for automated deduction
Install
Dune Dependency
Authors
Maintainers
Sources
dolmen-0.10.tbz
sha256=c5c85f77e3924f378e8d82f166eefe4131b4e041bf9cdeca467410f33c71fa61
sha512=42feb39d13cfdc8a2054abe85ccc47755f45059cda7d95e9261b5a9fd5c730f420732547b3fa19c4af059474f887ef78c119ab5933375a5ea2dbe888f65a3e4f
doc/src/dolmen.intf/language.ml.html
Source file language.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 47 48 49 50
(* This file is free software, part of dolmen. See file "LICENSE" formore information *) (** Interface for Dolmen languages modules *) module type S = sig type file (** Meta-data about locations in files. *) type token (** The type of tokens produced by the language lexer. *) type statement (** The type of top-level directives recognised by the parser. *) module Lexer : Lex.S with type token := token (** The Lexer module for the language. *) module Parser : Parse.S with type token := token and type statement := statement (** The Parser module for the language. *) val find : ?dir:string -> string -> string option (** Helper function to find a file using a language specification. Separates directory and file because most include directives in languages are relative to the directory of the original file being processed. *) val parse_all : [ `Stdin | `File of string | `Contents of string * string ] -> file * statement list Lazy.t (** Whole input parsing. Given an input to read (either a file, stdin, or some contents of the form [(filename, s)] where [s] is the contents to parse), returns a lazy list of the parsed statements. Forcing the lazy list may raise an exception if some error occurs during parsing (e.g. lexing or parsing error). *) val parse_input : [ `Stdin | `File of string | `Contents of string * string ] -> file * (unit -> statement option) * (unit -> unit) (** Incremental parsing. Given an input to read (either a file, stdin, or some contents of the form [(filename, s)] where [s] is the contents to parse), returns a generator that will incrementally parse the statements, together with a cleanup function to close file descriptors. In case of a syntax error, the current line will be completely consumed and parsing will restart at the beginning of the next line. Useful to process input from [stdin], or even large files where it would be impractical to parse the entire file before processing it. *) end
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>