From 75ce05693134e096c9ef7ab0704651870465e650 Mon Sep 17 00:00:00 2001 From: Jon Ludlam Date: Wed, 16 Jan 2013 00:02:22 +0000 Subject: [PATCH] CA-96872: Fix marshalling of exceptions Api_errors are of type string * string list, but they are actually marshalled as just a string list Signed-off-by: Jon Ludlam --- ocaml/idl/ocaml_backend/gen_api.ml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ocaml/idl/ocaml_backend/gen_api.ml b/ocaml/idl/ocaml_backend/gen_api.ml index 429a1946d9..73b1146844 100644 --- a/ocaml/idl/ocaml_backend/gen_api.ml +++ b/ocaml/idl/ocaml_backend/gen_api.ml @@ -132,11 +132,11 @@ let gen_client_types highapi = (List.between [""] [ [ "open Date" ]; [ - "type failure = string * (string list) with rpc"; + "type failure = (string list) with rpc"; "let response_of_failure code params ="; - " Rpc.failure (rpc_of_failure (code, params))"; + " Rpc.failure (rpc_of_failure (code::params))"; "let response_of_fault code ="; - " Rpc.failure (rpc_of_failure (\"Fault\", [code]))"; + " Rpc.failure (rpc_of_failure ([\"Fault\"; code]))"; ]; [ "include Rpc"; "type string_list = string list with rpc";