This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Possible parenthesizing bug


The following line from cp/lex.c:do_scoped_id generates a warning from gcc:

      if (parsing && yychar == '(' || yychar == LEFT_RIGHT)

I think it lacks a pair of parentheses.  Is that correct?


Tue Mar  3 10:27:30 1998  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>

	* lex.c (do_scoped_id): Fix parenthesizing.

--- egcs-980302/gcc/cp/lex.c.~1~	Mon Mar  2 18:37:06 1998
+++ egcs-980302/gcc/cp/lex.c	Tue Mar  3 10:27:00 1998
@@ -2987,7 +2987,7 @@
 	  LOOKUP_EXPR_GLOBAL (id) = 1;
 	  return id;
 	}
-      if (parsing && yychar == '(' || yychar == LEFT_RIGHT)
+      if (parsing && (yychar == '(' || yychar == LEFT_RIGHT))
 	id = implicitly_declare (token);
       else
 	{


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]