This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Cygwin warning elimination: gcc.c:3480: warning: suggest parentheses ...
- To: "'gcc-patches at gcc dot gnu dot org'" <gcc-patches at gcc dot gnu dot org>
- Subject: Cygwin warning elimination: gcc.c:3480: warning: suggest parentheses ...
- From: "Billinghurst, David (CRTS)" <David dot Billinghurst at riotinto dot com>
- Date: Tue, 10 Apr 2001 01:43:25 -0000
Eliminate a couple more warnings in gcc.c for cygwin and other platforms
that define HAVE_EXECUTABLE_SUFFIX. Bootstrapped on 3.0 branch on
i386-pc-cygwin.
/usr/local/src/gcc/gcc/gcc.c: In function `process_command':
/usr/local/src/gcc/gcc/gcc.c:3480: warning: suggest parentheses around
assignment used as truth value
/usr/local/src/gcc/gcc/gcc.c:3482: warning: suggest parentheses around
assignment used as truth value
fixed by adding parentheses
2001-04-10 David Billinghurst <David.Billinghurst@riotinto.org>
* gcc.c (process_command) Add parentheses to eliminate two warnings
--- gcc.c.orig Mon Apr 9 22:11:22 2001
+++ gcc.c Mon Apr 9 22:26:03 2001
@@ -3477,9 +3480,9 @@
have_c = 1;
break;
}
- else if (skip = SWITCH_TAKES_ARG (argv[j][1]))
+ else if ( (skip = SWITCH_TAKES_ARG (argv[j][1])) )
j += skip - (argv[j][2] != 0);
- else if (skip = WORD_SWITCH_TAKES_ARG (argv[j] +
1))
+ else if ( (skip = WORD_SWITCH_TAKES_ARG (argv[j] +
1)) )
j += skip;
}
j++;