diff options
author | Jacques Garrigue <garrigue at math.nagoya-u.ac.jp> | 2000-03-28 08:47:47 +0000 |
---|---|---|
committer | Jacques Garrigue <garrigue at math.nagoya-u.ac.jp> | 2000-03-28 08:47:47 +0000 |
commit | db2e8dec76e17bd0987dd0a12ad7509b6e63d97c (patch) | |
tree | 65f6ec5acc0c6d9020f1fb5b0dcb32bd4fe8bca3 /otherlibs/labltk/compiler/tsort.ml | |
parent | e3f1ab289da91f2d382afc824ade6c6e3b5eb764 (diff) |
adapte aux labels legers
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@3005 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
Diffstat (limited to 'otherlibs/labltk/compiler/tsort.ml')
-rw-r--r-- | otherlibs/labltk/compiler/tsort.ml | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/otherlibs/labltk/compiler/tsort.ml b/otherlibs/labltk/compiler/tsort.ml index 4f0d49692..246eca2db 100644 --- a/otherlibs/labltk/compiler/tsort.ml +++ b/otherlibs/labltk/compiler/tsort.ml @@ -62,13 +62,13 @@ let sort order = let q = Queue.create () and result = ref [] in List.iter !order - fun:(function {pred_count = n} as node -> + f:(function {pred_count = n} as node -> if n = 0 then Queue.add node q); begin try while true do let t = Queue.take q in result := t.node :: !result; - List.iter t.successors fun: + List.iter t.successors f: begin fun s -> let n = s.pred_count - 1 in s.pred_count <- n; @@ -78,7 +78,7 @@ let sort order = with Queue.Empty -> List.iter !order - fun:(fun node -> if node.pred_count <> 0 + f:(fun node -> if node.pred_count <> 0 then raise Cyclic) end; !result |