From 5833971a52a4e6e078988fa88738e5a5180cce36 Mon Sep 17 00:00:00 2001 From: Ryan Kavanagh Date: Tue, 2 Jun 2020 14:27:47 -0400 Subject: Split common parsing functions into separate function --- gemini/parseCommon.mli | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 gemini/parseCommon.mli (limited to 'gemini/parseCommon.mli') diff --git a/gemini/parseCommon.mli b/gemini/parseCommon.mli new file mode 100644 index 0000000..2994e6e --- /dev/null +++ b/gemini/parseCommon.mli @@ -0,0 +1,18 @@ +module type PARSE_COMMON = +sig + val is_letter : char -> bool + + val is_digit : char -> bool + + val is_whitespace : char -> bool + + val is_cr : char -> bool + + val lift_or : ('a -> bool) -> ('a -> bool) -> 'a -> bool + + val skip_spaces : unit Angstrom.t + + val take_till_cr : string Angstrom.t +end + +module ParseCommon : PARSE_COMMON -- cgit v1.2.3