Module Versioned_file.MakeSource

Parameters

module Data : sig ... end

Signature

Sourcemodule Lang : sig ... end
Sourceval load_exn : Stdune.Path.t -> f:(Lang.Instance.t -> 'a Decoder.t) -> 'a

load_exn fn ~f loads a versioned file. It parses the first line, looks up the language, checks that the version is supported and parses the rest of the file with f.

Sourceval parse_contents : Lexing.lexbuf -> f:(Lang.Instance.t -> 'a Decoder.t) -> 'a

Parse the contents of a versioned file after the first line has been read.