Joseph Myers <j...@polyomino.org.uk> wrote:

> On Mon, 16 Jul 2018, Vincent Lefevre wrote:
>
> > As expected, the text in http://austingroupbugs.net/view.php?id=1108
> > makes Debian's c99 utility behave incorrectly. FYI, I've reported a
> > bug:
>
> While I think the changes proposed for issue8 are wrong, they clearly 
> can't result in a bug in any c99 utility, since issue8 will surely have a 
> corresponding utility for a later version of the C standard, and not a c99 
> utility at all.

Signed integer overflow can only trigger undefined behavior in case that more 
than a single specific architecture could be envolved.

Since POSIX de-facto only allowed two's complement machines since several years 
already (the current change is just fixing the slipped parts in the standard), 
it is now well defined what happens in case of an integer overflow.

Since the C++ people already think about making this to happen in ther next 
standard, it seems that the C compilers may do something similar in the future.

There is a small difference: C is being used for more platforms than just a 
POSIX OS. The integer overflow related warnings may be needed for other targets 
and could be switched on in case that the compiler is called with flags that 
refer to non-POSIX embedded targets.



Jörg

-- 
 EMail:jo...@schily.net                    (home) Jörg Schilling D-13353 Berlin
    joerg.schill...@fokus.fraunhofer.de (work) Blog: http://schily.blogspot.com/
 URL: http://cdrecord.org/private/ http://sf.net/projects/schilytools/files/'

Reply via email to