Commits

Anonymous committed e5988f1

Minor changes.

Comments (0)

Files changed (1)

 	 unit -> Beapi.bmessage =
 	"bmessage_constructor_3"
 external bmessage_AddData :
-	Beapi.bmessage -> string -> type_code -> pointer -> ssize_t -> bool -> int -> status_t =
+	Beapi.bmessage -> string -> Beapi.type_code -> Beapi.pointer -> Beapi.ssize_t -> bool -> int -> Beapi.status_t =
 	"bmessage_AddData_native"
 	"bmessage_AddData_bytecode"
 external bmessage_AddBool :
-	Beapi.bmessage -> string -> bool -> status_t =
+	Beapi.bmessage -> string -> bool -> Beapi.status_t =
 	"bmessage_AddBool"
 external bmessage_AddInt8 :
-	Beapi.bmessage -> string -> int8 -> status_t =
+	Beapi.bmessage -> string -> int8 -> Beapi.status_t =
 	"bmessage_AddInt8"
 external bmessage_AddInt16 :
-	Beapi.bmessage -> string -> int16 -> status_t =
+	Beapi.bmessage -> string -> int16 -> Beapi.status_t =
 	"bmessage_AddInt16"
 external bmessage_AddInt32 :
-	Beapi.bmessage -> string -> int -> status_t =
+	Beapi.bmessage -> string -> int -> Beapi.status_t =
 	"bmessage_AddInt32"
 external bmessage_AddInt64 :
-	Beapi.bmessage -> string -> int64 -> status_t =
+	Beapi.bmessage -> string -> int64 -> Beapi.status_t =
 	"bmessage_AddInt64"
 external bmessage_AddFloat :
-	Beapi.bmessage -> string -> float -> status_t =
+	Beapi.bmessage -> string -> float -> Beapi.status_t =
 	"bmessage_AddFloat"
 external bmessage_AddDouble :
-	Beapi.bmessage -> string -> double -> status_t =
+	Beapi.bmessage -> string -> double -> Beapi.status_t =
 	"bmessage_AddDouble"
 external bmessage_AddString_1 :
-	string -> string -> status_t =
+	string -> string -> Beapi.status_t =
 	"bmessage_AddString_1"
 external bmessage_AddString_2 :
-	string -> bstring -> status_t =
+	string -> Beapi.bstring -> Beapi.status_t =
 	"bmessage_AddString_2"
 external bmessage_AddPoint :
-	Beapi.bmessage -> string ->  Beapi.bpoint -> status_t =
+	Beapi.bmessage -> string ->  Beapi.bpoint -> Beapi.status_t =
 	"bmessage_AddPoint"
 external bmessage_AddRect :
-	Beapi.bmessage -> string -> brect -> status_t =
+	Beapi.bmessage -> string -> Beapi.brect -> Beapi.status_t =
 	"bmessage_AddRect"
 external bmessage_AddRef :
-	Beapi.bmessage -> string -> entry_ref -> status_t =
+	Beapi.bmessage -> string -> Beapi.entry_ref -> Beapi.status_t =
 	"bmessage_AddRef"
 external bmessage_AddMessage :
-	Beapi.bmessage -> string -> Beapi.bmessage -> status_t =
+	Beapi.bmessage -> string -> Beapi.bmessage -> Beapi.status_t =
 	"bmessage_AddMessage"
 external bmessage_AddMessenger :
-	Beapi.bmessage -> string -> bmessenger -> status_t =
+	Beapi.bmessage -> string -> Beapi.bmessenger -> Beapi.status_t =
 	"bmessage_AddMessenger"
 external bmessage_AddPointer :
-	Beapi.bmessage -> string -> pointer -> status_t =
+	Beapi.bmessage -> string -> Beapi.pointer -> Beapi.status_t =
 	"bmessage_AddPointer"
 external bmessage_AddFlat :
-	Beapi.bmessage -> string -> bflattenable -> int -> status_t =
+	Beapi.bmessage -> string -> bflattenable -> int -> Beapi.status_t =
 	"bmessage_AddFlat"
 external bmessage_AddSpecifier_1 :
-	Beapi.bmessage -> status_t =
+	Beapi.bmessage -> Beapi.status_t =
 	"bmessage_AddSpecifier_1"
 external bmessage_AddSpecifier_2 :
-	string -> status_t =
+	string -> Beapi.status_t =
 	"bmessage_AddSpecifier_2"
 external bmessage_AddSpecifier_3 :
-	string -> int -> status_t =
+	string -> int -> Beapi.status_t =
 	"bmessage_AddSpecifier_3"
 external bmessage_AddSpecifier_4 :
-	string -> int -> int -> status_t =
+	string -> int -> int -> Beapi.status_t =
 	"bmessage_AddSpecifier_4"
 external bmessage_AddSpecifier_5 :
-	string -> string -> status_t =
+	string -> string -> Beapi.status_t =
 	"bmessage_AddSpecifier_5"
 external bmessage_CountNames :
-	Beapi.bmessage -> type_code -> int =
+	Beapi.bmessage -> Beapi.type_code -> int =
 	"bmessage_CountNames"
 external bmessage_FindData_1 :
-	string -> type_code -> int -> void -> ssize_t -> status_t =
+	string -> Beapi.type_code -> int -> void -> Beapi.ssize_t -> Beapi.status_t =
 	"bmessage_FindData_1"
 external bmessage_FindData_2 :
-	string -> type_code -> void -> ssize_t -> status_t =
+	string -> Beapi.type_code -> void -> Beapi.ssize_t -> Beapi.status_t =
 	"bmessage_FindData_2"
 external bmessage_FindBool_1 :
-	string -> int -> bool -> status_t =
+	string -> int -> bool -> Beapi.status_t =
 	"bmessage_FindBool_1"
 external bmessage_FindBool_2 :
-	string -> bool -> status_t =
+	string -> bool -> Beapi.status_t =
 	"bmessage_FindBool_2"
 external bmessage_FindInt8_1 :
-	string -> int -> int8 -> status_t =
+	string -> int -> int8 -> Beapi.status_t =
 	"bmessage_FindInt8_1"
 external bmessage_FindInt8_2 :
-	string -> int8 -> status_t =
+	string -> int8 -> Beapi.status_t =
 	"bmessage_FindInt8_2"
 external bmessage_FindInt16_1 :
-	string -> int -> int16 -> status_t =
+	string -> int -> int16 -> Beapi.status_t =
 	"bmessage_FindInt16_1"
 external bmessage_FindInt16_2 :
-	string -> int16 -> status_t =
+	string -> int16 -> Beapi.status_t =
 	"bmessage_FindInt16_2"
 external bmessage_FindInt32_1 :
-	string -> int -> int32 -> status_t =
+	string -> int -> int32 -> Beapi.status_t =
 	"bmessage_FindInt32_1"
 external bmessage_FindInt32_2 :
-	string -> int32 -> status_t =
+	string -> int32 -> Beapi.status_t =
 	"bmessage_FindInt32_2"
 external bmessage_FindInt64_1 :
-	string -> int -> int64 -> status_t =
+	string -> int -> int64 -> Beapi.status_t =
 	"bmessage_FindInt64_1"
 external bmessage_FindInt64_2 :
-	string -> int64 -> status_t =
+	string -> int64 -> Beapi.status_t =
 	"bmessage_FindInt64_2"
 external bmessage_FindFloat_1 :
-	string -> int -> float -> status_t =
+	string -> int -> float -> Beapi.status_t =
 	"bmessage_FindFloat_1"
 external bmessage_FindFloat_2 :
-	string -> float -> status_t =
+	string -> float -> Beapi.status_t =
 	"bmessage_FindFloat_2"
 external bmessage_FindDouble_1 :
-	string -> int -> double -> status_t =
+	string -> int -> double -> Beapi.status_t =
 	"bmessage_FindDouble_1"
 external bmessage_FindDouble_2 :
-	string -> double -> status_t =
+	string -> double -> Beapi.status_t =
 	"bmessage_FindDouble_2"
 external bmessage_FindString_1 :
-	string -> int -> char -> status_t =
+	string -> int -> char -> Beapi.status_t =
 	"bmessage_FindString_1"
 external bmessage_FindString_2 :
-	string -> char -> status_t =
+	string -> char -> Beapi.status_t =
 	"bmessage_FindString_2"
 external bmessage_FindString_3 :
-	string -> int -> bstring -> status_t =
+	string -> int -> Beapi.bstring -> Beapi.status_t =
 	"bmessage_FindString_3"
 external bmessage_FindString_4 :
-	string -> bstring -> status_t =
+	string -> Beapi.bstring -> Beapi.status_t =
 	"bmessage_FindString_4"
 external bmessage_FindPoint_1 :
-	string -> int ->  Beapi.bpoint -> status_t =
+	string -> int ->  Beapi.bpoint -> Beapi.status_t =
 	"bmessage_FindPoint_1"
 external bmessage_FindPoint_2 :
-	string ->  Beapi.bpoint -> status_t =
+	string ->  Beapi.bpoint -> Beapi.status_t =
 	"bmessage_FindPoint_2"
 external bmessage_FindRect_1 :
-	string -> int -> brect -> status_t =
+	string -> int -> Beapi.brect -> Beapi.status_t =
 	"bmessage_FindRect_1"
 external bmessage_FindRect_2 :
-	string -> brect -> status_t =
+	string -> Beapi.brect -> Beapi.status_t =
 	"bmessage_FindRect_2"
 external bmessage_FindRef_1 :
-	string -> int -> entry_ref -> status_t =
+	string -> int -> Beapi.entry_ref -> Beapi.status_t =
 	"bmessage_FindRef_1"
 external bmessage_FindRef_2 :
-	string -> entry_ref -> status_t =
+	string -> Beapi.entry_ref -> Beapi.status_t =
 	"bmessage_FindRef_2"
 external bmessage_FindMessage_1 :
-	string -> int -> Beapi.bmessage -> status_t =
+	string -> int -> Beapi.bmessage -> Beapi.status_t =
 	"bmessage_FindMessage_1"
 external bmessage_FindMessage_2 :
-	string -> Beapi.bmessage -> status_t =
+	string -> Beapi.bmessage -> Beapi.status_t =
 	"bmessage_FindMessage_2"
 external bmessage_FindMessenger_1 :
-	string -> int -> bmessenger -> status_t =
+	string -> int -> Beapi.bmessenger -> Beapi.status_t =
 	"bmessage_FindMessenger_1"
 external bmessage_FindMessenger_2 :
-	string -> bmessenger -> status_t =
+	string -> Beapi.bmessenger -> Beapi.status_t =
 	"bmessage_FindMessenger_2"
 external bmessage_FindPointer_1 :
-	string -> int -> void -> status_t =
+	string -> int -> void -> Beapi.status_t =
 	"bmessage_FindPointer_1"
 external bmessage_FindPointer_2 :
-	string -> void -> status_t =
+	string -> void -> Beapi.status_t =
 	"bmessage_FindPointer_2"
 external bmessage_FindFlat_1 :
-	string -> int -> bflattenable -> status_t =
+	string -> int -> bflattenable -> Beapi.status_t =
 	"bmessage_FindFlat_1"
 external bmessage_FindFlat_2 :
-	string -> bflattenable -> status_t =
+	string -> bflattenable -> Beapi.status_t =
 	"bmessage_FindFlat_2"
 external bmessage_Flatten_1 :
-	bdataio -> ssize_t -> status_t =
+	bdataio -> Beapi.ssize_t -> Beapi.status_t =
 	"bmessage_Flatten_1"
 external bmessage_Flatten_2 :
-	string -> ssize_t -> status_t =
+	string -> Beapi.ssize_t -> Beapi.status_t =
 	"bmessage_Flatten_2"
 external bmessage_Unflatten_1 :
-	bdataio -> status_t =
+	bdataio -> Beapi.status_t =
 	"bmessage_Unflatten_1"
 external bmessage_Unflatten_2 :
-	string -> status_t =
+	string -> Beapi.status_t =
 	"bmessage_Unflatten_2"
 external bmessage_FlattenedSize :
-	Beapi.bmessage -> ssize_t =
+	Beapi.bmessage -> Beapi.ssize_t =
 	"bmessage_FlattenedSize"
 external bmessage_GetCurrentSpecifier :
-	Beapi.bmessage -> int32 -> Beapi.bmessage -> int32 -> char -> status_t =
+	Beapi.bmessage -> int32 -> Beapi.bmessage -> int32 -> char -> Beapi.status_t =
 	"bmessage_GetCurrentSpecifier"
 external bmessage_PopSpecifier :
-	Beapi.bmessage -> status_t =
+	Beapi.bmessage -> Beapi.status_t =
 	"bmessage_PopSpecifier"
 external bmessage_GetInfo_1 :
-	string -> type_code -> int32 -> status_t =
+	string -> Beapi.type_code -> int32 -> Beapi.status_t =
 	"bmessage_GetInfo_1"
 external bmessage_GetInfo_2 :
-	string -> type_code -> bool -> status_t =
+	string -> Beapi.type_code -> bool -> Beapi.status_t =
 	"bmessage_GetInfo_2"
 external bmessage_GetInfo_3 :
-	type_code -> int -> char -> type_code -> int32 -> status_t =
+	Beapi.type_code -> int -> char -> Beapi.type_code -> int32 -> Beapi.status_t =
 	"bmessage_GetInfo_3"
 external bmessage_HasSpecifiers :
 	Beapi.bmessage -> bool =
 	Beapi.bmessage -> bool =
 	"bmessage_IsSystem"
 external bmessage_MakeEmpty :
-	Beapi.bmessage -> status_t =
+	Beapi.bmessage -> Beapi.status_t =
 	"bmessage_MakeEmpty"
 external bmessage_IsEmpty :
 	Beapi.bmessage -> bool =
 	Beapi.bmessage -> unit =
 	"bmessage_PrintToStream"
 external bmessage_RemoveName :
-	Beapi.bmessage -> string -> status_t =
+	Beapi.bmessage -> string -> Beapi.status_t =
 	"bmessage_RemoveName"
 external bmessage_RemoveData :
-	Beapi.bmessage -> string -> int -> status_t =
+	Beapi.bmessage -> string -> int -> Beapi.status_t =
 	"bmessage_RemoveData"
 external bmessage_ReplaceData_1 :
-	string -> type_code -> pointer -> ssize_t -> status_t =
+	string -> Beapi.type_code -> Beapi.pointer -> Beapi.ssize_t -> Beapi.status_t =
 	"bmessage_ReplaceData_1"
 external bmessage_ReplaceData_2 :
-	string -> type_code -> int -> pointer -> ssize_t -> status_t =
+	string -> Beapi.type_code -> int -> Beapi.pointer -> Beapi.ssize_t -> Beapi.status_t =
 	"bmessage_ReplaceData_2"
 external bmessage_ReplaceBool_1 :
-	string -> bool -> status_t =
+	string -> bool -> Beapi.status_t =
 	"bmessage_ReplaceBool_1"
 external bmessage_ReplaceBool_2 :
-	string -> int -> bool -> status_t =
+	string -> int -> bool -> Beapi.status_t =
 	"bmessage_ReplaceBool_2"
 external bmessage_ReplaceInt8_1 :
-	string -> int8 -> status_t =
+	string -> int8 -> Beapi.status_t =
 	"bmessage_ReplaceInt8_1"
 external bmessage_ReplaceInt8_2 :
-	string -> int -> int8 -> status_t =
+	string -> int -> int8 -> Beapi.status_t =
 	"bmessage_ReplaceInt8_2"
 external bmessage_ReplaceInt16_1 :
-	string -> int16 -> status_t =
+	string -> int16 -> Beapi.status_t =
 	"bmessage_ReplaceInt16_1"
 external bmessage_ReplaceInt16_2 :
-	string -> int -> int16 -> status_t =
+	string -> int -> int16 -> Beapi.status_t =
 	"bmessage_ReplaceInt16_2"
 external bmessage_ReplaceInt32_1 :
-	string -> int -> status_t =
+	string -> int -> Beapi.status_t =
 	"bmessage_ReplaceInt32_1"
 external bmessage_ReplaceInt32_2 :
-	string -> int -> int -> status_t =
+	string -> int -> int -> Beapi.status_t =
 	"bmessage_ReplaceInt32_2"
 external bmessage_ReplaceInt64_1 :
-	string -> int64 -> status_t =
+	string -> int64 -> Beapi.status_t =
 	"bmessage_ReplaceInt64_1"
 external bmessage_ReplaceInt64_2 :
-	string -> int -> int64 -> status_t =
+	string -> int -> int64 -> Beapi.status_t =
 	"bmessage_ReplaceInt64_2"
 external bmessage_ReplaceFloat_1 :
-	string -> float -> status_t =
+	string -> float -> Beapi.status_t =
 	"bmessage_ReplaceFloat_1"
 external bmessage_ReplaceFloat_2 :
-	string -> int -> float -> status_t =
+	string -> int -> float -> Beapi.status_t =
 	"bmessage_ReplaceFloat_2"
 external bmessage_ReplaceDouble_1 :
-	string -> double -> status_t =
+	string -> double -> Beapi.status_t =
 	"bmessage_ReplaceDouble_1"
 external bmessage_ReplaceDouble_2 :
-	string -> int -> double -> status_t =
+	string -> int -> double -> Beapi.status_t =
 	"bmessage_ReplaceDouble_2"
 external bmessage_ReplaceString_1 :
-	string -> string -> status_t =
+	string -> string -> Beapi.status_t =
 	"bmessage_ReplaceString_1"
 external bmessage_ReplaceString_2 :
-	string -> int -> string -> status_t =
+	string -> int -> string -> Beapi.status_t =
 	"bmessage_ReplaceString_2"
 external bmessage_ReplacePoint_1 :
-	string ->  Beapi.bpoint -> status_t =
+	string ->  Beapi.bpoint -> Beapi.status_t =
 	"bmessage_ReplacePoint_1"
 external bmessage_ReplacePoint_2 :
-	string -> int ->  Beapi.bpoint -> status_t =
+	string -> int ->  Beapi.bpoint -> Beapi.status_t =
 	"bmessage_ReplacePoint_2"
 external bmessage_ReplaceRect_1 :
-	string -> brect -> status_t =
+	string -> Beapi.brect -> Beapi.status_t =
 	"bmessage_ReplaceRect_1"
 external bmessage_ReplaceRect_2 :
-	string -> int -> brect -> status_t =
+	string -> int -> Beapi.brect -> Beapi.status_t =
 	"bmessage_ReplaceRect_2"
 external bmessage_ReplaceRef_1 :
-	string -> entry_ref -> status_t =
+	string -> Beapi.entry_ref -> Beapi.status_t =
 	"bmessage_ReplaceRef_1"
 external bmessage_ReplaceRef_2 :
-	string -> int -> entry_ref -> status_t =
+	string -> int -> Beapi.entry_ref -> Beapi.status_t =
 	"bmessage_ReplaceRef_2"
 external bmessage_ReplaceMessage_1 :
-	string -> Beapi.bmessage -> status_t =
+	string -> Beapi.bmessage -> Beapi.status_t =
 	"bmessage_ReplaceMessage_1"
 external bmessage_ReplaceMessage_2 :
-	string -> int -> Beapi.bmessage -> status_t =
+	string -> int -> Beapi.bmessage -> Beapi.status_t =
 	"bmessage_ReplaceMessage_2"
 external bmessage_ReplaceMessenger_1 :
-	string -> bmessenger -> status_t =
+	string -> Beapi.bmessenger -> Beapi.status_t =
 	"bmessage_ReplaceMessenger_1"
 external bmessage_ReplaceMessenger_2 :
-	string -> int -> bmessenger -> status_t =
+	string -> int -> Beapi.bmessenger -> Beapi.status_t =
 	"bmessage_ReplaceMessenger_2"
 external bmessage_ReplacePointer_1 :
-	string -> pointer -> status_t =
+	string -> Beapi.pointer -> Beapi.status_t =
 	"bmessage_ReplacePointer_1"
 external bmessage_ReplacePointer_2 :
-	string -> int -> pointer -> status_t =
+	string -> int -> Beapi.pointer -> Beapi.status_t =
 	"bmessage_ReplacePointer_2"
 external bmessage_ReplaceFlat_1 :
-	string -> bflattenable -> status_t =
+	string -> bflattenable -> Beapi.status_t =
 	"bmessage_ReplaceFlat_1"
 external bmessage_ReplaceFlat_2 :
-	string -> int -> bflattenable -> status_t =
+	string -> int -> bflattenable -> Beapi.status_t =
 	"bmessage_ReplaceFlat_2"
 external bmessage_ReturnAddress :
-	Beapi.bmessage -> bmessenger =
+	Beapi.bmessage -> Beapi.bmessenger =
 	"bmessage_ReturnAddress"
 external bmessage_SendReply_1 :
-	Beapi.bmessage -> Beapi.bmessage -> bigtime_t -> bigtime_t -> status_t =
+	Beapi.bmessage -> Beapi.bmessage -> Beapi.bigtime_t -> Beapi.bigtime_t -> Beapi.status_t =
 	"bmessage_SendReply_1"
 external bmessage_SendReply_2 :
-	Beapi.bmessage -> bhandler -> bigtime_t -> status_t =
+	Beapi.bmessage -> Beapi.bhandler -> Beapi.bigtime_t -> Beapi.status_t =
 	"bmessage_SendReply_2"
 external bmessage_SendReply_3 :
-	int -> Beapi.bmessage -> status_t =
+	int -> Beapi.bmessage -> Beapi.status_t =
 	"bmessage_SendReply_3"
 external bmessage_SendReply_4 :
-	int -> bhandler -> status_t =
+	int -> Beapi.bhandler -> Beapi.status_t =
 	"bmessage_SendReply_4"
 external bmessage_WasDelivered :
 	Beapi.bmessage -> bool =
 
 
 
-	let bmessage ?message ?command () =
-		match message, command with
-		| None, Some command -> bmessage_constructor_1 command
-		| Some message, None -> bmessage_constructor_2 message
-		| None, None -> bmessage_constructor_3 
-		| None, None -> invalid_arg "Wrong arg in BMessage.constructor"
+let bmessage ?message ?command () =
+	match message, command with
+	| None, Some command -> bmessage_constructor_1 command
+	| Some message, None -> bmessage_constructor_2 message
+	| None, None -> bmessage_constructor_3 
+	| None, None -> invalid_arg "Wrong arg in BMessage.constructor"
 
 
 	let add_data ~self ~name ~data_type ~data ~numBytes ~fixedSize ~numItems () =
 		| None, None, None -> invalid_arg "Wrong arg in BMessage.FindFlat"
 
 
-	let flatten ?numBytes ?object ?address ?numBytes () =
-		match numBytes, object, address, numBytes with
-		| Some numBytes, Some object, None, None -> bmessage_Flatten_1 object numBytes
+	let flatten ?numBytes ?obj ?address ?numBytes () =
+		match numBytes, obj, address, numBytes with
+		| Some numBytes, Some obj, None, None -> bmessage_Flatten_1 obj numBytes
 		| None, None, Some address, Some numBytes -> bmessage_Flatten_2 address numBytes
 		| None, None, None, None -> invalid_arg "Wrong arg in BMessage.Flatten"
 
 
-	let unflatten ?object ?address () =
-		match object, address with
-		| Some object, None -> bmessage_Unflatten_1 object
+	let unflatten ?obj ?address () =
+		match obj, address with
+		| Some obj, None -> bmessage_Unflatten_1 obj
 		| None, Some address -> bmessage_Unflatten_2 address
 		| None, None -> invalid_arg "Wrong arg in BMessage.Unflatten"
 
 	let pop_specifier ~self () =
 		bmessage_PopSpecifier self
 
-	let get_info ?countFound ?nameFound ?fixedSize ?type ?index ?typeFound ?name () =
-		match countFound, nameFound, fixedSize, type, index, typeFound, name with
+	let get_info ?countFound ?nameFound ?fixedSize ?data_type ?index ?typeFound ?name () =
+		match countFound, nameFound, fixedSize, data_type, index, typeFound, name with
 		| Some countFound, None, None, None, None, Some typeFound, Some name -> bmessage_GetInfo_1 name typeFound countFound
 		| None, None, Some fixedSize, None, None, Some typeFound, Some name -> bmessage_GetInfo_2 name typeFound fixedSize
-		| Some countFound, Some nameFound, None, Some type, Some index, Some typeFound, None -> bmessage_GetInfo_3 type index nameFound typeFound countFound
+		| Some countFound, Some nameFound, None, Some data_type, Some index, Some typeFound, None -> bmessage_GetInfo_3 data_type index nameFound typeFound countFound
 		| None, None, None, None, None, None, None -> invalid_arg "Wrong arg in BMessage.GetInfo"
 
 
 		| None, None, None -> invalid_arg "Wrong arg in BMessage.ReplacePointer"
 
 
-	let replace_flat ?object ?index ?name () =
-		match object, index, name with
-		| Some object, None, Some name -> bmessage_ReplaceFlat_1 name object
-		| Some object, Some index, Some name -> bmessage_ReplaceFlat_2 name index object
+	let replace_flat ?obj ?index ?name () =
+		match obj, index, name with
+		| Some obj, None, Some name -> bmessage_ReplaceFlat_1 name obj
+		| Some obj, Some index, Some name -> bmessage_ReplaceFlat_2 name index obj
 		| None, None, None -> invalid_arg "Wrong arg in BMessage.ReplaceFlat"