avr-gcc-list
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-gcc-list] [Bug target/35634] New: [avr] result of char promotio


From: Dmitry K.
Subject: Re: [avr-gcc-list] [Bug target/35634] New: [avr] result of char promotion comes out of CHAR_MIN/MAX
Date: Thu, 20 Mar 2008 08:43:02 +1000
User-agent: KMail/1.5

On Wednesday 19 March 2008 22:17, Paulo Marques wrote:
> Is this strictly wrong, from the C definition point of view?
>
> I know that signed overflow is "undefined". How does this test case
> interacts with -fwrapv and -fno-strict-overflow?
>
> For those unaware of signed overflow issues, there is a nice sum up here:
>
> http://www.airs.com/blog/archives/120
>
> I know that turning "undefined" into an "out of range" result is ugly,
> but so is signed overflow....

Thanks, I will read this article, very interesting.

Now I can not understand, why the Standart permits
'undefined behavior' with ordinary overflow, like
result of usage uninitialized pointer for writing.
In any case the Standart does not charge to force
the 'undefined behavior'.

Regards,
Dmitry.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]