Introducing kscanf, the scanning function that has an extra
continuation argument for scanning failures. git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@4949 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02master
parent
9e3dc0cd97
commit
72d45abf8a
|
@ -44,7 +44,7 @@ val from_function : (unit -> char) -> scanbuf;;
|
|||
|
||||
end;;
|
||||
|
||||
exception Scan_failure of string;;
|
||||
exception Scan_failure of Scanning.scanbuf * string;;
|
||||
(** The exception that formatted input functions raise when the input
|
||||
cannot be read according to the given format. *)
|
||||
|
||||
|
@ -129,3 +129,6 @@ val sscanf : string -> ('a, Scanning.scanbuf, 'b) format -> 'a -> 'b;;
|
|||
|
||||
val scanf : ('a, Scanning.scanbuf, 'b) format -> 'a -> 'b;;
|
||||
(** Same as {!Scanf.bscanf}, but inputs from [stdin]. *)
|
||||
|
||||
val kscanf : Scanning.scanbuf -> ('a, 'b, 'c) format ->
|
||||
'a -> (Scanning.scanbuf -> string -> 'c) -> 'c;;
|
||||
|
|
Loading…
Reference in New Issue