Re: [PATCH v3] staging: fbtft: replace empty macro args with identity converter
From: Andy Shevchenko
Date: Mon Apr 13 2026 - 01:59:50 EST
On Sun, Apr 12, 2026 at 8:33 PM Baker <mzndmzn@xxxxxxxxx> wrote:
>
> The define_fbtft_write_reg macro calls 'modifier' as a function.
> Passing an empty token as modifier is undefined behavior in C for
> fixed-arity macros. Introduce fbtft_no_conv() as an identity
> function to replace the empty args in the no-conversion cases.
This trick is used in the kernel (usually for u8). If you really want
to improve, use _Generic() instead.
--
With Best Regards,
Andy Shevchenko