[PATCHv2 wayland 0/8] wayland-scanner: produce code with c99 initializers

Pekka Paalanen ppaalanen at gmail.com
Wed Jun 20 10:23:48 UTC 2018


On Tue, 19 Jun 2018 17:43:47 +0100
Emil Velikov <emil.l.velikov at gmail.com> wrote:

> On 18 June 2018 at 11:36, Pekka Paalanen <ppaalanen at gmail.com> wrote:
> > On Thu, 14 Jun 2018 16:49:37 +0100
> > Emil Velikov <emil.l.velikov at gmail.com> wrote:
> >  
> >> Hi all,
> >>
> >> Here's a take v2 of the series, with the following changes:
> >>  - don't trim trailing NULL entries from the wl_interfaces* array
> >>  - updated tests - separate patches to ease review, to be squashed
> >>
> >> On the question of why, despite the aesthetics these patches make the
> >> generated files actually understandable by a human being...  
> >
> > Hi Emil,
> >
> > on the previous round, this concern was raised:
> >  
> Thanks, did not spot that one.
> 
> 
> > On Tue, 13 Feb 2018 13:36:06 +0000
> > Daniel Stone <daniel at fooishbar.org> wrote:
> >  
> >> But that being said, my worry is that we don't actually control the
> >> compilation environment for the scanner output. Scanner output
> >> currently compiles with '-pedantic -ansi -Wall -Wextra' (at least,
> >> when inline is defined). This patch changes that requirement, and I
> >> worry that - like previous discussions on changing scanner output -
> >> that upgrading Wayland would lead to people hitting compilation
> >> failures.  
> >
> > What is your rationale for that being a non-issue?
> >  
> According to [1] GCC has supported designated initializers since v3.0,
> released some 17 years ago [2].
> Clang has supported them from a very early age. On the Windows front
> MSVC 2013 introduced support and it EOL.
> 
> Other less common compilers (say the Sun/Oracle or Intel ones) are
> fine as well - although I cannot give you exact details.
> 
> In other words unless someone does one of the following two they're
> perfectly fine.
>  - uses unsupported (ancient?) compiler, or
>  - explicitly sets -pedantic -ansi _and_ -Werror
> 
> In the case they do, they should seriously reconsider what they're
> inflicting on themselves.
> Both from functionality and security POV.

Ok. So '-pedantic -ansi' will still compile, even if with warnings?
Ansi being equivalent to -std=c90 it seems.

I can accept that. Is anyone against this change?


Thanks,
pq


> 
> -Emil
> 
> [1] https://gcc.gnu.org/c99status.html
> [2] https://gcc.gnu.org/releases.html

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <https://lists.freedesktop.org/archives/wayland-devel/attachments/20180620/798d8b9d/attachment.sig>


More information about the wayland-devel mailing list