Module Frontend.Debugging

Some helpers for debugging

val lexer_logging : bool Core.ref

Controls whether the lexing operations get logged

val lexer_logger : string -> unit
val lexer_pos_logger : Stdlib.Lexing.position -> unit
val grammar_logging : bool Core.ref

Controls whether the parsing operations get logged

val grammar_logger : string -> unit
val ast_printing : bool Core.ref

Controls whether an AST gets printed during parsing

val ast_to_string : Ast.untyped_program -> string
val ast_logger : Ast.untyped_program -> unit
val typed_ast_printing : bool Core.ref

Controls whether a decorated AST gets printed after the semantic check

val typed_ast_to_string : Ast.typed_program -> string
val typed_ast_logger : Ast.typed_program -> unit