This is the mail archive of the
mailing list for the GCC project.
Re: Bug with compound literal initializer?
- From: Jonathan Wakely <jwakely dot gcc at gmail dot com>
- To: Martin Sebor <msebor at redhat dot com>
- Cc: Alexey Neyman <stilor at att dot net>, "gcc at gcc dot gnu dot org" <gcc at gcc dot gnu dot org>
- Date: Wed, 25 Mar 2015 19:06:36 +0000
- Subject: Re: Bug with compound literal initializer?
- Authentication-results: sourceware.org; auth=none
- References: <5511D668 dot 5060009 at att dot net> <5512EBB0 dot 4070601 at redhat dot com> <5512FC1F dot 6030201 at att dot net> <55130440 dot 5080601 at redhat dot com>
On 25 March 2015 at 18:53, Martin Sebor wrote:
> This was my mistake because specifying -ansi after -std=c11
> overrides the latter with -std=c90. (It would be nice if
> the driver warned about one option overriding another.)
In general that's useful, so you can add e.g. -O0 to the end of a
command and override any previous -O option, but when the two options
are spelled differently it might be useful. I've seen almost exactly
this mistake before with someone using -std=c++11 -ansi.