This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: PR 25512: pointer overflow defined?
- From: Andrew Haley <aph at redhat dot com>
- To: Richard Guenther <rguenther at suse dot de>
- Cc: gcc at gcc dot gnu dot org
- Date: Wed, 21 Dec 2005 12:44:58 +0000
- Subject: Re: PR 25512: pointer overflow defined?
- References: <Pine.LNX.4.63.0512211332070.6048@t148.fhfr.qr>
Richard Guenther writes:
>
> The problem in this PR is that code like in the testcase (from
> OpenOffice) assumes that pointer overflow is defined. As the
> standard does not talk about wrapping pointer semantics at all (at
> least I couldn't find anything about that), how should we treat
> this?
Look at Section 6.5.6, Para 8. The code is undefined.
Andrew.