On Mon, Oct 24, 2011 at 2:05 PM, Jason Merrill wrote:
> On 10/24/2011 02:47 PM, Gabriel Dos Reis wrote:
>>
>> What about (testcase)
>>
>> int f(char);
>> double f(...);
>>
>> const int n = sizeof f({257});
>>
>> ?
>
> The narrowing conversion would be marked as 'bad' and therefore t
On 10/24/2011 02:47 PM, Gabriel Dos Reis wrote:
What about (testcase)
int f(char);
double f(...);
const int n = sizeof f({257});
?
The narrowing conversion would be marked as 'bad' and therefore the
second overload chosen. As before, the objective is to only change the
d
On Mon, Oct 24, 2011 at 1:17 PM, Jason Merrill wrote:
> On 10/24/2011 02:13 PM, Gabriel Dos Reis wrote:
>> The problem is with C++11 codes. There is no reason for them to be
>> subjected
>> to the inconsistency, especially for codes in header files that are
>> upgraded (beyond control of the end
On 10/24/2011 02:13 PM, Gabriel Dos Reis wrote:
yes, but how does the compiler distinguish a "legacy code" compiled
under C++11 from non-legacy C++11 code?
It doesn't.
The problem is with C++11 codes. There is no reason for them to be subjected
to the inconsistency, especially for codes in h
On Mon, Oct 24, 2011 at 12:46 PM, Jason Merrill wrote:
> On 10/24/2011 01:21 PM, Gabriel Dos Reis wrote:
>>
>> On Mon, Oct 24, 2011 at 9:53 AM, Jason Merrill wrote:
>> So, if you make -Wno-narrowing meaningful in C++11 mode then how can
>> it not affect sfinae (case 1.b.) and still be consistent
On 10/24/2011 01:21 PM, Gabriel Dos Reis wrote:
On Mon, Oct 24, 2011 at 9:53 AM, Jason Merrill wrote:
So, if you make -Wno-narrowing meaningful in C++11 mode then how can
it not affect sfinae (case 1.b.) and still be consistent with the
other case where a diagnostic is required the expression ac
On Mon, Oct 24, 2011 at 9:53 AM, Jason Merrill wrote:
> On 10/24/2011 10:39 AM, Gabriel Dos Reis wrote:
>>
>> Hmm, the narrowing semantics also affects SFINAE, not just simple
>> declaration.
>> If we want a flag that can also affect the outcome of overload
>> resolution, it should one of the the
On 10/24/2011 10:39 AM, Gabriel Dos Reis wrote:
Hmm, the narrowing semantics also affects SFINAE, not just simple declaration.
If we want a flag that can also affect the outcome of overload
resolution, it should one of the the -fflags, such as -fpermissive.
I don't want the option to affect SFI
On Mon, Oct 24, 2011 at 9:10 AM, Jason Merrill wrote:
> On 10/24/2011 09:49 AM, Gabriel Dos Reis wrote:
>>
>> On Mon, Oct 24, 2011 at 8:29 AM, Jason Merrill wrote:
>>>
>>> Right, -Wno-long-long is only useful in C++03 and C90. But it does in
>>> fact
>>> suppress a standard diagnostic.
>>
>> a d
On 10/24/2011 09:49 AM, Gabriel Dos Reis wrote:
On Mon, Oct 24, 2011 at 8:29 AM, Jason Merrill wrote:
Right, -Wno-long-long is only useful in C++03 and C90. But it does in fact
suppress a standard diagnostic.
a diagnostic of an extension :-)
I'm not going to argue semantics any further. W
On Mon, Oct 24, 2011 at 8:29 AM, Jason Merrill wrote:
> On 10/24/2011 09:26 AM, Gabriel Dos Reis wrote:
>>
>> On Mon, Oct 24, 2011 at 8:06 AM, Jason Merrill wrote:
>
>>> No. I added -Wno-narrowing specifically to suppress the diagnostic in
>>> C++0x
>>> mode; see c++/49793. There are several di
.. just to let you know guys, I'm already unassigned from the PR, but
today I wanted to give it one (actually 3) more try. Given the
controversy, I don't feel like further following the issue, it just
makes me nervous. Eventually, feel free to adjust my patches to your likes.
Paolo.
On 10/24/2011 09:26 AM, Gabriel Dos Reis wrote:
On Mon, Oct 24, 2011 at 8:06 AM, Jason Merrill wrote:
No. I added -Wno-narrowing specifically to suppress the diagnostic in C++0x
mode; see c++/49793. There are several diagnostics required by standards
that can be suppressed by -Wno- flags, s
On Mon, Oct 24, 2011 at 8:06 AM, Jason Merrill wrote:
> On 10/24/2011 07:47 AM, Paolo Carlini wrote:
[...]
>> and also, as
>> requested by Gaby, preventing -Wno-narrowing from suppressing the
>> warning in C++0x mode (if the user really needs to silence it,
>> -Wno-c++0x-compat works). I also adde
On 10/24/2011 09:06 AM, Jason Merrill wrote:
On 10/24/2011 07:47 AM, Paolo Carlini wrote:
the below is a new variant removing -Wc++0x-compat from -Wall (cannot be
added to -Wextra either because bootstrap passes -W)
I don't understand the rationale for this. If the warning is problematic
for b
On 10/24/2011 07:47 AM, Paolo Carlini wrote:
the below is a new variant removing -Wc++0x-compat from -Wall (cannot be
added to -Wextra either because bootstrap passes -W)
I don't understand the rationale for this. If the warning is
problematic for bootstrap, why not just add -Wno-narrowing to
On Mon, Oct 24, 2011 at 7:18 AM, Paolo Carlini wrote:
> Hi,
>>
>> On Mon, Oct 24, 2011 at 6:47 AM, Paolo Carlini
>> wrote:
>>>
>>> Hi,
>>>
>>> the below is a new variant removing -Wc++0x-compat from -Wall (cannot be
>>> added to -Wextra either because bootstrap passes -W) and also, as
>>> request
On 10/24/2011 02:18 PM, Paolo Carlini wrote:
OK with a minor correction. This bit
+With -std=c++0x, @option{-Wno-c++0x-compat} can be used to suppress
+the diagnostic required by the standard.
should not be there. It is currently an accident of implementation
detail as opposed to a feature.
Hi,
On Mon, Oct 24, 2011 at 6:47 AM, Paolo Carlini wrote:
Hi,
the below is a new variant removing -Wc++0x-compat from -Wall (cannot be
added to -Wextra either because bootstrap passes -W) and also, as requested
by Gaby, preventing -Wno-narrowing from suppressing the warning in C++0x
mode (if t
On Mon, Oct 24, 2011 at 6:47 AM, Paolo Carlini wrote:
> Hi,
>
> the below is a new variant removing -Wc++0x-compat from -Wall (cannot be
> added to -Wextra either because bootstrap passes -W) and also, as requested
> by Gaby, preventing -Wno-narrowing from suppressing the warning in C++0x
> mode (
Hi,
the below is a new variant removing -Wc++0x-compat from -Wall (cannot be
added to -Wextra either because bootstrap passes -W) and also, as
requested by Gaby, preventing -Wno-narrowing from suppressing the
warning in C++0x mode (if the user really needs to silence it,
-Wno-c++0x-compat wor
21 matches
Mail list logo