From 31cc05e3151dbdb82ad322b5a2fc3911b11cf016 Mon Sep 17 00:00:00 2001
From: mmitchel <mmitchel@138bc75d-0d04-0410-961f-82ee72b054a4>
Date: Tue, 8 Feb 2005 04:11:04 +0000
Subject: [PATCH] 	* parser.c (cp_lexer_start_debugging): Avoid
 arithmetic operations 	on boolean variables. 	(cp_lexer_stop_debugging):
 Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@94731 138bc75d-0d04-0410-961f-82ee72b054a4
---
 gcc/cp/ChangeLog | 6 ++++++
 gcc/cp/parser.c  | 4 ++--
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index 32e664533d50..5cb874205534 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,3 +1,9 @@
+2005-02-07  Mark Mitchell  <mark@codesourcery.com>
+
+	* parser.c (cp_lexer_start_debugging): Avoid arithmetic operations
+	on boolean variables.
+	(cp_lexer_stop_debugging): Likewise.
+
 2005-02-03  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
 
 	PR c++/17401
diff --git a/gcc/cp/parser.c b/gcc/cp/parser.c
index 82d665ed8104..54e330f737ae 100644
--- a/gcc/cp/parser.c
+++ b/gcc/cp/parser.c
@@ -706,7 +706,7 @@ cp_lexer_print_token (FILE * stream, cp_token *token)
 static void
 cp_lexer_start_debugging (cp_lexer* lexer)
 {
-  ++lexer->debugging_p;
+  lexer->debugging_p = true;
 }
 
 /* Stop emitting debugging information.  */
@@ -714,7 +714,7 @@ cp_lexer_start_debugging (cp_lexer* lexer)
 static void
 cp_lexer_stop_debugging (cp_lexer* lexer)
 {
-  --lexer->debugging_p;
+  lexer->debugging_p = false;
 }
 
 #endif /* ENABLE_CHECKING */
-- 
GitLab