Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions ast/import.ml
Original file line number Diff line number Diff line change
Expand Up @@ -211,4 +211,6 @@ module Parse = struct
let core_type lexbuf = core_type lexbuf |> Of_ocaml.copy_core_type
let expression lexbuf = expression lexbuf |> Of_ocaml.copy_expression
let pattern lexbuf = pattern lexbuf |> Of_ocaml.copy_pattern

let comments_in_last_parse = comments_in_last_parse
end
2 changes: 2 additions & 0 deletions astlib/parse.ml
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
include Ocaml_common.Parse

let comments_in_last_parse = Ocaml_common.Lexer.comments
3 changes: 3 additions & 0 deletions astlib/parse.mli
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,6 @@ val expression : Lexing.lexbuf -> Parsetree.expression

val pattern : Lexing.lexbuf -> Parsetree.pattern
(** Parse a pattern *)

val comments_in_last_parse : unit -> (string * Location.t) list
(** Get the comments from the last parse *)
Loading