From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3184 invoked by alias); 29 Nov 2005 07:44:54 -0000 Received: (qmail 3171 invoked by alias); 29 Nov 2005 07:44:51 -0000 Date: Tue, 29 Nov 2005 07:44:00 -0000 Message-ID: <20051129074451.3170.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug c/25151] GCC issues warnings to a syntactically correct expression. In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "mishabear at gmail dot com" 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 X-SW-Source: 2005-11/txt/msg03935.txt.bz2 List-Id: ------- Comment #2 from mishabear at gmail dot com 2005-11-29 07:44 ------- Subject: Re: GCC issues warnings to a syntactically correct expression. In fact I want to do something lik this: int main() { int ia[10]; int *pi, i; i=10; pi = ( ((i>=0) && (i<10)) ? (pi=&(ia[i]), i=(i+1)%10, pi) : (pi=0) ); return 0; } and I don't think there are any semantical problems. 29 Nov 2005 06:28:10 -0000, pinskia at gcc dot gnu dot org : > > > ------- Comment #1 from pinskia at gcc dot gnu dot org 2005-11-29 06:28 ------- > Note the warning is to warn things like: > a = a++; > which is syntactically correct but semantically questionable. > > Note there are a lot of things which are syntactially correct but are > semantically questionable > > > -- > > pinskia at gcc dot gnu dot org changed: > > What |Removed |Added > ---------------------------------------------------------------------------- > Keywords| |diagnostic > Known to fail| |4.0.3 > > > http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25151 > > ------- You are receiving this mail because: ------- > You reported the bug, or are watching the reporter. > -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25151