Re: [PATCH 5/9] of: property: implement the .property_get_names() fwnode operation

From: Alejandro Colomar

Date: Tue Nov 10 2026 - 06:39:02 EST


Hi Andy,

> Date: 2026-11-10 12:51:53+0200
> From: Andy Shevchenko <andy.shevchenko@xxxxxxxxx>
>
[...]
> > drivers/base/property.c: In function ‘fwnode_property_get_names’:
> > drivers/base/property.c:607:36: error: passing argument 1 of ‘match_string’ from incompatible pointer type [-Wincompatible-pointer-types]
>
> > And I don't see a good way of working around it without doing:
> >
> > match_string((const char *const)merged, n1, sec_props.array[i]));
> >
> > which is ugly.
>
> Ah, got it! But why is the "merges" char ** and not char * const *? I
> believe that will fix the issue.

It solves it in C++, and will solve it in C2y, but doesn't solve it in
current C.
<https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3987.htm>


Have a lovely day!
Alex

--
<https://www.alejandro-colomar.es>

Attachment: signature.asc
Description: PGP signature