aboutsummaryrefslogtreecommitdiff
path: root/lib/analyzer.mli
blob: 43509baf30d78108ff3564ce4c1c00226f389a05 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
type error = {
  message : string;
  start_pos : Lexing.position;
  end_pos : Lexing.position;
}

val format_error : Format.formatter -> error -> unit

val parse :
  (module Qsp_syntax.S.Analyzer with type Location.repr = 'a) ->
  (module Encoding.S) ->
  Sedlexing.lexbuf ->
  ('a, error) Result.t
(** Read the source and build a analyzis over it. 

This method make the link between the source file and how to read it
(encoding…) and the AST we want to build. *)