Eric Kohl : widl: Rename some variables.
Alexandre Julliard
julliard at wine.codeweavers.com
Thu Dec 8 07:06:18 CST 2005
Module: wine
Branch: refs/heads/master
Commit: 80e262202f1ed411be5c777937969be99ba0f1bd
URL: http://source.winehq.org/git/?p=wine.git;a=commit;h=80e262202f1ed411be5c777937969be99ba0f1bd
Author: Eric Kohl <eric.kohl at t-online.de>
Date: Thu Dec 8 12:45:45 2005 +0100
widl: Rename some variables.
---
tools/widl/client.c | 50 +++++++++++++++++++++++++-------------------------
tools/widl/server.c | 40 ++++++++++++++++++++--------------------
2 files changed, 45 insertions(+), 45 deletions(-)
diff --git a/tools/widl/client.c b/tools/widl/client.c
index ce6eda4..c7d5d48 100644
--- a/tools/widl/client.c
+++ b/tools/widl/client.c
@@ -67,7 +67,7 @@ static int print_client( const char *for
static void write_procformatstring(type_t *iface)
{
- func_t *cur = iface->funcs;
+ func_t *func = iface->funcs;
print_client("static const MIDL_PROC_FORMAT_STRING __MIDL_ProcFormatString =\n");
print_client("{\n");
@@ -76,10 +76,10 @@ static void write_procformatstring(type_
print_client("{\n");
indent++;
- while (NEXT_LINK(cur)) cur = NEXT_LINK(cur);
- while (cur)
+ while (NEXT_LINK(func)) func = NEXT_LINK(func);
+ while (func)
{
- var_t *def = cur->def;
+ var_t *def = func->def;
if (is_void(def->type, NULL))
{
@@ -92,7 +92,7 @@ static void write_procformatstring(type_
print_client("0x%02x, /* <type> */\n", def->type->type);
}
- cur = PREV_LINK(cur);
+ func = PREV_LINK(func);
}
print_client("0x0\n");
@@ -124,23 +124,23 @@ static void write_typeformatstring(void)
static void write_function_stubs(type_t *iface)
{
- func_t *cur = iface->funcs;
- char *handle_name = get_attrp(iface->attrs, ATTR_IMPLICIT_HANDLE);
+ func_t *func = iface->funcs;
+ char *implicit_handle = get_attrp(iface->attrs, ATTR_IMPLICIT_HANDLE);
int method_count = 0;
unsigned int proc_offset = 0;
- while (NEXT_LINK(cur)) cur = NEXT_LINK(cur);
- while (cur)
+ while (NEXT_LINK(func)) func = NEXT_LINK(func);
+ while (func)
{
- var_t *def = cur->def;
+ var_t *def = func->def;
write_type(client, def->type, def, def->tname);
fprintf(client, " ");
write_name(client, def);
fprintf(client, "(\n");
indent++;
- if (cur->args)
- write_args(client, cur->args, iface->name, 0, TRUE);
+ if (func->args)
+ write_args(client, func->args, iface->name, 0, TRUE);
else
print_client("void");
fprintf(client, ")\n");
@@ -158,7 +158,7 @@ static void write_function_stubs(type_t
fprintf(client, " _RetVal;\n");
}
- if (handle_name)
+ if (implicit_handle)
print_client("RPC_BINDING_HANDLE _Handle = 0;\n");
print_client("RPC_MESSAGE _RpcMessage;\n");
@@ -177,8 +177,8 @@ static void write_function_stubs(type_t
indent--;
fprintf(client, "\n");
- if (handle_name)
- print_client("_Handle = %s;\n", handle_name);
+ if (implicit_handle)
+ print_client("_Handle = %s;\n", implicit_handle);
/* FIXME: marshal arguments */
print_client("_StubMsg.BufferLength = 0UL;\n");
@@ -187,7 +187,7 @@ static void write_function_stubs(type_t
indent++;
print_client("(PMIDL_STUB_MESSAGE)&_StubMsg,\n");
print_client("_StubMsg.BufferLength,\n");
- if (handle_name)
+ if (implicit_handle)
print_client("%_Handle);\n");
else
print_client("%s__MIDL_AutoBindHandle);\n", iface->name);
@@ -259,7 +259,7 @@ static void write_function_stubs(type_t
fprintf(client, "\n");
method_count++;
- cur = PREV_LINK(cur);
+ func = PREV_LINK(func);
}
}
@@ -280,7 +280,7 @@ static void write_stubdescdecl(type_t *i
static void write_stubdescriptor(type_t *iface)
{
- char *handle_name = get_attrp(iface->attrs, ATTR_IMPLICIT_HANDLE);
+ char *implicit_handle = get_attrp(iface->attrs, ATTR_IMPLICIT_HANDLE);
print_client("static const MIDL_STUB_DESC %s_StubDesc =\n", iface->name);
print_client("{\n");
@@ -288,8 +288,8 @@ static void write_stubdescriptor(type_t
print_client("(void __RPC_FAR *)& %s___RpcClientInterface,\n", iface->name);
print_client("MIDL_user_allocate,\n");
print_client("MIDL_user_free,\n");
- if (handle_name)
- print_client("&%s,\n", handle_name);
+ if (implicit_handle)
+ print_client("&%s,\n", implicit_handle);
else
print_client("&%s__MIDL_AutoBindHandle,\n", iface->name);
print_client("0,\n");
@@ -357,18 +357,18 @@ static void write_formatdesc( const char
static void write_formatstringsdecl(type_t *iface)
{
- func_t *cur;
+ func_t *func;
int byte_count = 1;
print_client("#define TYPE_FORMAT_STRING_SIZE %d\n", 3); /* FIXME */
/* determine the proc format string size */
- cur = iface->funcs;
- while (NEXT_LINK(cur)) cur = NEXT_LINK(cur);
- while (cur)
+ func = iface->funcs;
+ while (NEXT_LINK(func)) func = NEXT_LINK(func);
+ while (func)
{
byte_count += 2; /* FIXME: determine real size */
- cur = PREV_LINK(cur);
+ func = PREV_LINK(func);
}
print_client("#define PROC_FORMAT_STRING_SIZE %d\n", byte_count);
diff --git a/tools/widl/server.c b/tools/widl/server.c
index 1c48e25..8629ef9 100644
--- a/tools/widl/server.c
+++ b/tools/widl/server.c
@@ -69,7 +69,7 @@ static int print_server(const char *form
static void write_procformatstring(type_t *iface)
{
- func_t *cur = iface->funcs;
+ func_t *func = iface->funcs;
print_server("static const MIDL_PROC_FORMAT_STRING __MIDL_ProcFormatString =\n");
print_server("{\n");
@@ -78,10 +78,10 @@ static void write_procformatstring(type_
print_server("{\n");
indent++;
- while (NEXT_LINK(cur)) cur = NEXT_LINK(cur);
- while (cur)
+ while (NEXT_LINK(func)) func = NEXT_LINK(func);
+ while (func)
{
- var_t *def = cur->def;
+ var_t *def = func->def;
if (is_void(def->type, NULL))
{
@@ -94,7 +94,7 @@ static void write_procformatstring(type_
print_server("0x%02x, /* <type> */\n", def->type->type);
}
- cur = PREV_LINK(cur);
+ func = PREV_LINK(func);
}
print_server("0x0\n");
@@ -149,11 +149,11 @@ static unsigned int get_required_stack_s
static void write_function_stubs(type_t *iface)
{
- func_t *cur = iface->funcs;
- while (NEXT_LINK(cur)) cur = NEXT_LINK(cur);
- while (cur)
+ func_t *func = iface->funcs;
+ while (NEXT_LINK(func)) func = NEXT_LINK(func);
+ while (func)
{
- var_t *def = cur->def;
+ var_t *def = func->def;
write_type(server, def->type, def, def->tname);
fprintf(server, " __RPC_STUB\n");
@@ -260,7 +260,7 @@ static void write_function_stubs(type_t
fprintf(server, "}\n");
fprintf(server, "\n");
- cur = PREV_LINK(cur);
+ func = PREV_LINK(func);
}
}
@@ -269,22 +269,22 @@ static void write_dispatchtable(type_t *
{
unsigned long ver = get_attrv(iface->attrs, ATTR_VERSION);
unsigned long method_count = 0;
- func_t *cur = iface->funcs;
+ func_t *func = iface->funcs;
print_server("static RPC_DISPATCH_FUNCTION %s_table[] =\n", iface->name);
print_server("{\n");
indent++;
- while (NEXT_LINK(cur)) cur = NEXT_LINK(cur);
- while (cur)
+ while (NEXT_LINK(func)) func = NEXT_LINK(func);
+ while (func)
{
- var_t *def = cur->def;
+ var_t *def = func->def;
print_server("%s_", iface->name);
write_name(server, def);
fprintf(server, ",\n");
method_count++;
- cur = PREV_LINK(cur);
+ func = PREV_LINK(func);
}
print_server("0\n");
indent--;
@@ -382,18 +382,18 @@ static void write_formatdesc( const char
static void write_formatstringsdecl(type_t *iface)
{
- func_t *cur;
+ func_t *func;
int byte_count = 1;
print_server("#define TYPE_FORMAT_STRING_SIZE %d\n", 3); /* FIXME */
/* determine the proc format string size */
- cur = iface->funcs;
- while (NEXT_LINK(cur)) cur = NEXT_LINK(cur);
- while (cur)
+ func = iface->funcs;
+ while (NEXT_LINK(func)) func = NEXT_LINK(func);
+ while (func)
{
byte_count += 2; /* FIXME: determine real size */
- cur = PREV_LINK(cur);
+ func = PREV_LINK(func);
}
print_server("#define PROC_FORMAT_STRING_SIZE %d\n", byte_count);
More information about the wine-cvs
mailing list