[PATCH] widl: Support basic char type

Rémi Bernon rbernon at codeweavers.com
Thu Mar 3 03:20:13 CST 2022


On 3/3/22 08:09, Alistair Leslie-Hughes wrote:
> Signed-off-by: Alistair Leslie-Hughes <leslie_alistair at hotmail.com>
> ---
>   tools/widl/typetree.c | 4 +++-
>   1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/tools/widl/typetree.c b/tools/widl/typetree.c
> index dc4db35e835..aa8c302c064 100644
> --- a/tools/widl/typetree.c
> +++ b/tools/widl/typetree.c
> @@ -226,10 +226,12 @@ static size_t append_type_signature(char **buf, size_t *len, size_t pos, type_t
>           case TYPE_BASIC_DOUBLE:
>               n += strappend(buf, len, pos + n, "f8");
>               return n;
> +        case TYPE_BASIC_CHAR:
> +            n += strappend(buf, len, pos + n, type_basic_get_sign(type) <= 0 ? "i1" : "u1");
> +            return n;
>           case TYPE_BASIC_INT16:
>           case TYPE_BASIC_INT3264:
>           case TYPE_BASIC_LONG:
> -        case TYPE_BASIC_CHAR:
>           case TYPE_BASIC_HYPER:
>           case TYPE_BASIC_BYTE:
>           case TYPE_BASIC_WCHAR:

Is this required for something specifically? I couldn't find any 
indication in the specification [1] how these would translate in the 
signatures.

[1] https://docs.microsoft.com/en-us/uwp/winrt-cref/winrt-type-system
-- 
Rémi Bernon <rbernon at codeweavers.com>



More information about the wine-devel mailing list