Commit 4ce943a7 authored by gerd's avatar gerd

Bugfix: When Record(_,_) records in a loop, the state of the

variable was not cleared after every cycle. This is done now.


git-svn-id: https://godirepo.camlcity.org/svn/lib-xstr/[email protected] e4cd5726-45db-0310-8eb3-84e3bb775810
parent bb2ed18b
(* $Id: xstr_match.ml,v 1.2 1999/07/04 20:02:07 gerd Exp $
(* $Id: xstr_match.ml,v 1.3 1999/07/05 21:42:46 gerd Exp $
* ----------------------------------------------------------------------
* String matching
*)
......@@ -289,7 +289,12 @@ let match_string_at ml s k =
else begin
r.begun <- true;
r.from <- k;
run k (recorded @ (Record(r,[]) :: ml')) recs
try
run k (recorded @ (Record(r,[]) :: ml')) recs
with
Not_found ->
r.begun <- false;
raise Not_found
end
| Scanner f :: ml' ->
let n = f (String.sub s k (len-k)) in
......@@ -597,6 +602,10 @@ let mknegset s =
* History:
*
* $Log: xstr_match.ml,v $
* Revision 1.3 1999/07/05 21:42:46 gerd
* Bugfix: When Record(_,_) records in a loop, the state of the
* variable was not cleared after every cycle. This is done now.
*
* Revision 1.2 1999/07/04 20:02:07 gerd
* Added Lazystring, Lazystring_from.
* Added replace_matched_substring function.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment