diff options
Diffstat (limited to 'library')
-rw-r--r-- | library/lib.ml | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/library/lib.ml b/library/lib.ml index d0a015bd9..4d95bdce9 100644 --- a/library/lib.ml +++ b/library/lib.ml @@ -63,14 +63,13 @@ let find_entry_p p = find !lib_stk let split_lib sp = - let rec findrec acc = function - | ((sp',obj) as hd)::t -> - if sp = sp' then (acc,hd,t) else findrec (hd::acc) t + let rec findrec after = function + | ((sp',obj) as hd)::before -> + if sp = sp' then (after,hd,before) else findrec (hd::after) before | [] -> error "no such entry" in findrec [] !lib_stk - (* Adding operations. *) let add_entry sp node = |