From 8df11a4cf7ab3b4c0c9a793312987bfc516d97a4 Mon Sep 17 00:00:00 2001 From: Xavier Leroy Date: Thu, 3 Jul 2003 08:34:08 +0000 Subject: [PATCH] Nettoyage dans extract_label_names git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@5645 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02 --- typing/typecore.ml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/typing/typecore.ml b/typing/typecore.ml index 3dab22d3c..723e24371 100644 --- a/typing/typecore.ml +++ b/typing/typecore.ml @@ -120,13 +120,13 @@ let rec extract_label_names sexp env ty = match ty.desc with | Tconstr (path, _, _) -> let td = Env.find_type path env in - let rec extract = function + begin match td.type_kind with | Type_record (fields, _, _) -> List.map (fun (name, _, _) -> name) fields | Type_abstract when td.type_manifest <> None -> extract_label_names sexp env (expand_head env ty) - | _ -> assert false in - extract td.type_kind + | _ -> assert false + end | _ -> assert false