From 6e482ee5afbd77b7e8163362f23d8c2a908ab781 Mon Sep 17 00:00:00 2001 From: Antonio Nuno Monteiro Date: Sun, 24 Feb 2019 21:43:13 +0000 Subject: [PATCH] Fix the `Angstrom.Buffered.state_to_option` docstring The docstring claimed to return `Some (bs, v)` when in reality it returns `Some v` --- lib/angstrom.mli | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/angstrom.mli b/lib/angstrom.mli index c86d0f0..e1fa550 100644 --- a/lib/angstrom.mli +++ b/lib/angstrom.mli @@ -535,12 +535,12 @@ module Buffered : sig copied into the state's buffer for later use by the caller. *) val state_to_option : 'a state -> 'a option - (** [state_to_option state] returns [Some (bs, v)] if the parser is in the + (** [state_to_option state] returns [Some v] if the parser is in the [Done (bs, v)] state and [None] otherwise. This function has no effect on the current state of the parser. *) val state_to_result : 'a state -> ('a, string) result - (** [state_to_result state] returns [Ok v] if the parser is in the [Done v] + (** [state_to_result state] returns [Ok v] if the parser is in the [Done (bs, v)] state and [Error msg] if it is in the [Fail] or [Partial] state. This function has no effect on the current state of the parser. *)