From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13837 invoked by alias); 6 May 2002 12:26:06 -0000 Mailing-List: contact gcc-prs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-prs-owner@gcc.gnu.org Received: (qmail 13811 invoked by uid 71); 6 May 2002 12:26:03 -0000 Date: Mon, 06 May 2002 05:26:00 -0000 Message-ID: <20020506122603.13804.qmail@sources.redhat.com> To: nobody@gcc.gnu.org Cc: gcc-prs@gcc.gnu.org, From: "Brian Ceccarelli" Subject: RE: c++/6568: g++3 (3.0.2) misinterpreting single byte hex constants Reply-To: "Brian Ceccarelli" X-SW-Source: 2002-05/txt/msg00147.txt.bz2 List-Id: The following reply was made to PR c++/6568; it has been noted by GNATS. From: "Brian Ceccarelli" To: , , , , , Cc: Subject: RE: c++/6568: g++3 (3.0.2) misinterpreting single byte hex constants Date: Mon, 6 May 2002 08:20:25 -0400 localhost:[17] /home/ceccareb/work % uname -a Linux localhost.localdomain 2.4.7-10 #1 Thu Sep 6 17:27:27 EDT 2001 i686 unknown localhost:[18] /home/ceccareb/work % g++3 -v Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/3.0.2/specs Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --disable-checking --host=i386-redha t-linux Thread model: posix gcc version 3.0.2 20010905 (Red Hat Linux 7.1 3.0.1-3) localhost:[42] /usr/src % localhost:[19] /home/ceccareb/work % cat test.cc # include int main(int argc, char *argv[]) { int i; char n; i = 0; n = (-1); printf("sizeof(i) = %d\n", sizeof i); printf("sizeof(n) = %d\n", sizeof n); if (n == 0xFF) printf("Yes. n = 0x%x\n", n); else printf("No. n = 0x%x\n", n); return 0; } localhost:[20] /home/ceccareb/work % g++3 test.cc test.cc: In function `int main(int, char**)': test.cc:17: warning: comparison is always false due to limited range of data type localhost:[21] /home/ceccareb/work % a.out sizeof(i) = 4 sizeof(n) = 1 No. n = 0xffffffff localhost:[22] /home/ceccareb/work % -----Original Message----- From: neil@gcc.gnu.org [mailto:neil@gcc.gnu.org] Sent: Monday, May 06, 2002 4:26 AM To: brian@talusmusic.com; gcc-bugs@gcc.gnu.org; gcc-prs@gcc.gnu.org; nobody@gcc.gnu.org Subject: Re: c++/6568: g++3 (3.0.2) misinterpreting single byte hex constants Synopsis: g++3 (3.0.2) misinterpreting single byte hex constants State-Changed-From-To: open->feedback State-Changed-By: neil State-Changed-When: Mon May 6 01:26:16 2002 State-Changed-Why: Missing testcase. Please reply to this e-mail with the 5-line test case in the body of your e-mail; without changing the subject line or the cc: list. That will ensure it goes into our bug system. http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&p r=6568