Ge van Geldorp <gvg(a)reactos.com> writes:
+ switch(var->type->type) + { + case RPC_FC_BYTE: + print_client("0x4e, /* FC_IN_PARAM_BASETYPE */\n"); + print_client("0x%02x, /* FC_BYTE */\n", RPC_FC_BYTE); + break; + case RPC_FC_CHAR: + print_client("0x4e, /* FC_IN_PARAM_BASETYPE */\n"); + print_client("0x%02x, /* FC_CHAR */\n", RPC_FC_CHAR); + break; + case RPC_FC_WCHAR: + print_client("0x4e, /* FC_IN_PARAM_BASETYPE */\n"); + print_client("0x%02x, /* FC_WCHAR */\n", RPC_FC_WCHAR); + break; + case RPC_FC_USHORT: + case RPC_FC_SHORT: + print_client("0x4e, /* FC_IN_PARAM_BASETYPE */\n"); + print_client("0x%02x, /* FC_USHORT */\n", RPC_FC_SHORT); + break; + case RPC_FC_ULONG: + case RPC_FC_LONG: + print_client("0x4e, /* FC_IN_PARAM_BASETYPE */\n"); + print_client("0x%02x, /* FC_LONG */\n", RPC_FC_LONG); + break; + case RPC_FC_HYPER: + print_client("0x4e, /* FC_IN_PARAM_BASETYPE */\n"); + print_client("0x%02x, /* FC_HYPER */\n", RPC_FC_HYPER); + break; + case RPC_FC_IGNORE: + print_client("0x4e, /* FC_IN_PARAM_BASETYPE */\n"); + print_client("0x%02x, /* FC_IGNORE */\n", RPC_FC_IGNORE); + break; + case RPC_FC_SMALL: + print_client("0x4e, /* FC_IN_PARAM_BASETYPE */\n"); + print_client("0x%02x, /* FC_SMALL */\n", RPC_FC_SMALL); + break; + case RPC_FC_FLOAT: + print_client("0x4e, /* FC_IN_PARAM_BASETYPE */\n"); + print_client("0x%02x, /* FC_FLOAT */\n", RPC_FC_FLOAT); + break; + case RPC_FC_DOUBLE: + print_client("0x4e, /* FC_IN_PARAM_BASETYPE */\n"); + print_client("0x%02x, /* FC_DOUBLE */\n", RPC_FC_DOUBLE); + break;
You should add some sort of get_fc_name() function instead of duplicating a big switch like that every time you want to print a name.
static void write_function_stubs(type_t *iface) { - func_t *cur = iface->funcs; - char *handle_name = get_attrp(iface->attrs, ATTR_IMPLICIT_HANDLE); + char *implicit_handle = get_attrp(iface->attrs, ATTR_IMPLICIT_HANDLE); + int explitit_handle = is_attr(iface->attrs, ATTR_IMPLICIT_HANDLE); + func_t *func = iface->funcs; + var_t* var;
Your patch would be a lot easier to review if you avoided renaming existing local variables. If you really think the names need to be changed please do it in a separate patch. -- Alexandre Julliard julliard(a)winehq.org