From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32691 invoked by alias); 24 Sep 2005 09:39:36 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 32668 invoked by uid 48); 24 Sep 2005 09:39:30 -0000 Date: Sat, 24 Sep 2005 09:39:00 -0000 Message-ID: <20050924093930.32667.qmail@sourceware.org> From: "falk at debian dot org" To: gcc-bugs@gcc.gnu.org In-Reply-To: <20050714131031.22485.mattias@virtutech.se> References: <20050714131031.22485.mattias@virtutech.se> Reply-To: gcc-bugzilla@gcc.gnu.org Subject: [Bug c/22485] pointer +- integer is never NULL X-Bugzilla-Reason: CC X-SW-Source: 2005-09/txt/msg02907.txt.bz2 List-Id: ------- Additional Comments From falk at debian dot org 2005-09-24 09:39 ------- (In reply to comment #21) > There have been lots of messages exchanged on this topic. It was just > pointed to me that the C++ standard -- unlike the C99 standard -- has the > following wording 5.7/7: Hmm, I missed that. So can we agree now the following implications are valid: int *p, *q, x; C99: q = p +- x formed => p nonnull, q nonnull x = p - q formed => p nonnull, q nonnull C++: q = p +- x formed, p nonnull => q nonnull q = p +- x formed, x nonnull => p nonnull, q nonnull x = p - q formed, p nonnull => q nonnull x = p - q formed, q nonnull => p nonnull -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=22485