[PATCH] libtest: Fix use of flexible array member

Sebastian Huber sebastian.huber at embedded-brains.de
Mon May 3 04:57:20 UTC 2021


On 02/05/2021 21:24, Joel Sherrill wrote:

>
> On Sun, May 2, 2021, 2:01 PM Sebastian Huber 
> <sebastian.huber at embedded-brains.de 
> <mailto:sebastian.huber at embedded-brains.de>> wrote:
>
>     Flexible array members must not appear in the middle of a structure.
>
>
> Any idea why this doesn't generate a warning? I thought this 
> restriction is well known.
Flexible array members in the middle of a structure are a GCC/clang 
extension. You only get a warning with -pedantic.

-- 
embedded brains GmbH
Herr Sebastian HUBER
Dornierstr. 4
82178 Puchheim
Germany
email: sebastian.huber at embedded-brains.de
phone: +49-89-18 94 741 - 16
fax:   +49-89-18 94 741 - 08

Registergericht: Amtsgericht München
Registernummer: HRB 157899
Vertretungsberechtigte Geschäftsführer: Peter Rasmussen, Thomas Dörfler
Unsere Datenschutzerklärung finden Sie hier:
https://embedded-brains.de/datenschutzerklaerung/



More information about the devel mailing list