@@ -421,25 +421,25 @@ let process_obj
421421 | Ignore ->
422422 External_arg_spec. empty_kind obj_arg_type,
423423 {param_type with ty = new_ty}::arg_types, result_types
424- | Arg_cst i ->
424+ | Arg_cst _ ->
425425 let s = Lam_methname. translate name in
426- {obj_arg_label = External_arg_spec. label s ( Some i) ;
426+ {obj_arg_label = External_arg_spec. obj_label s ;
427427 obj_arg_type },
428428 arg_types, (* ignored in [arg_types], reserved in [result_types] *)
429429 (({Asttypes. txt = name; loc} , [] , new_ty) :: result_types)
430430 | Nothing ->
431431 let s = (Lam_methname. translate name) in
432- {obj_arg_label = External_arg_spec. label s None ; obj_arg_type },
432+ {obj_arg_label = External_arg_spec. obj_label s ; obj_arg_type },
433433 {param_type with ty = new_ty}::arg_types,
434434 (({Asttypes. txt = name; loc} , [] , new_ty) :: result_types)
435435 | Int _ ->
436436 let s = Lam_methname. translate name in
437- {obj_arg_label = External_arg_spec. label s None ; obj_arg_type},
437+ {obj_arg_label = External_arg_spec. obj_label s ; obj_arg_type},
438438 {param_type with ty = new_ty}::arg_types,
439439 (({Asttypes. txt = name; loc}, [] , Ast_literal. type_int ~loc () ) :: result_types)
440440 | NullString _ ->
441441 let s = Lam_methname. translate name in
442- {obj_arg_label = External_arg_spec. label s None ; obj_arg_type},
442+ {obj_arg_label = External_arg_spec. obj_label s ; obj_arg_type},
443443 {param_type with ty = new_ty }::arg_types,
444444 (({Asttypes. txt = name; loc}, [] , Ast_literal. type_string ~loc () ) :: result_types)
445445 | Fn_uncurry_arity _ ->
@@ -967,8 +967,8 @@ let pval_prim_of_labels (labels : string Asttypes.loc list) =
967967 (fun {loc ; txt } arg_kinds
968968 ->
969969 let obj_arg_label =
970- External_arg_spec. label
971- (Lam_methname. translate txt) None in
970+ External_arg_spec. obj_label
971+ (Lam_methname. translate txt) in
972972 {obj_arg_type = Nothing ;
973973 obj_arg_label } :: arg_kinds
974974 ) in
@@ -991,7 +991,7 @@ let pval_prim_of_option_labels
991991 let obj_arg_label =
992992 if is_option then
993993 External_arg_spec. optional label_name
994- else External_arg_spec. label label_name None
994+ else External_arg_spec. obj_label label_name
995995 in
996996 {obj_arg_type = Nothing ;
997997 obj_arg_label } :: arg_kinds) in
0 commit comments