[patch]: [PATCH 1/2] widl: Implement async_uuid feature.

Alexandre Julliard julliard at winehq.org
Fri Sep 6 06:50:55 CDT 2013


Kai Tietz <ktietz70 at googlemail.com> writes:

> @@ -465,14 +465,14 @@ static void write_type_v(FILE *h, type_t *t, int is_field, int declonly, const c
>    }
>  }
>  
> -static void write_type_def_or_decl(FILE *f, type_t *t, int field, const char *name)
> +static void write_type_def_or_decl(FILE *f, type_t *t, int field, const char *name, const char *prename)
>  {
> -  write_type_v(f, t, field, FALSE, name);
> +  write_type_v(f, t, field, FALSE, name, prename);
>  }
>  
> -void write_type_decl(FILE *f, type_t *t, const char *name)
> +void write_type_decl(FILE *f, type_t *t, const char *name, const char *prename)
>  {
> -  write_type_v(f, t, FALSE, TRUE, name);
> +  write_type_v(f, t, FALSE, TRUE, name, prename);
>  }
>  
>  void write_type_decl_left(FILE *f, type_t *t)

It would be better to use some wrappers that change the names instead of
adding arguments to such low-level functions and then passing empty
strings 99% of the time.

> -static void write_c_method_def(FILE *header, const type_t *iface)
> +static void write_c_method_def(FILE *header, const type_t *iface, const char *prename, char fBeAsync)
>  {
> -  do_write_c_method_def(header, iface, iface->name);
> +  do_write_c_method_def(header, iface, iface->name, prename, fBeAsync);
>  }
>  
> -static void write_c_disp_method_def(FILE *header, const type_t *iface)
> +static void write_c_disp_method_def(FILE *header, const type_t *iface, const char *prename, char fBeAsync)
>  {
> -  do_write_c_method_def(header, type_iface_get_inherit(iface), iface->name);
> +  do_write_c_method_def(header, type_iface_get_inherit(iface), iface->name, prename, fBeAsync);
>  }
>  
> -static void write_method_proto(FILE *header, const type_t *iface)
> +static void write_method_proto(FILE *header, const type_t *iface, const char *prename, char fBeAsync)

Please try to keep widl free of Hungarion notation ugliness (and again,
a separate set of functions would probably be cleaner than adding flags
all over the place).

-- 
Alexandre Julliard
julliard at winehq.org



More information about the wine-patches mailing list