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/intf.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/intf.ml')
-rw-r--r-- | otherlibs/labltk/compiler/intf.ml | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/otherlibs/labltk/compiler/intf.ml b/otherlibs/labltk/compiler/intf.ml index d8e8310aa..4f646df34 100644 --- a/otherlibs/labltk/compiler/intf.ml +++ b/otherlibs/labltk/compiler/intf.ml @@ -24,24 +24,24 @@ let write_create_p :w wname = w "val create :\n ?name:string ->\n"; begin try - let option = Hashtbl.find types_table key:"options" in - let classdefs = List.assoc key:wname option.subtypes in - let tklabels = List.map fun:gettklabel classdefs in - let l = List.map classdefs fun: + let option = Hashtbl.find types_table "options" in + let classdefs = List.assoc wname option.subtypes in + let tklabels = List.map f:gettklabel classdefs in + let l = List.map classdefs f: begin fun fc -> begin let p = gettklabel fc in if count item:p tklabels > 1 then small fc.ml_name else p end, fc.template end in w (String.concat sep:" ->\n" - (List.map l fun: + (List.map l f: begin fun (s, t) -> " ?" ^ s ^ ":" ^(ppMLtype (match types_of_template t with | [t] -> labeloff t at:"write_create_p" | [] -> fatal_error "multiple" - | l -> Product (List.map fun:(labeloff at:"write_create_p") l))) + | l -> Product (List.map f:(labeloff at:"write_create_p") l))) end)) with Not_found -> fatal_error "in write_create_p" end; @@ -72,7 +72,7 @@ let write_function_type :w def = in let counter = ref 0 in List.iter (ls @ os @ us) - fun:(fun (l, t) -> labelprint :w l; w (ppMLtype t :counter); w " -> "); + f:(fun (l, t) -> labelprint :w l; w (ppMLtype t :counter); w " -> "); if (os <> [] || ls = []) && us = [] then w "unit -> "; w (ppMLtype any:true return:true def.result); (* RETURN TYPE !!! *) w " \n"; |