bison-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

maint: c++: fix printing of state number on streams


From: Akim Demaille
Subject: maint: c++: fix printing of state number on streams
Date: Sat, 23 May 2020 17:47:40 +0200

commit f32ba07f940b6efcdcee134dc382f1e7097d1087
Author: Akim Demaille <address@hidden>
Date:   Sat May 23 17:41:40 2020 +0200

    c++: fix printing of state number on streams
    
    Avoid this kind of display:
    
        LAC: checking lookahead identifier: R4 R3 G^B S5
    
    * data/skeletons/lalr1.cc: Convert state_t to int before printing it.

diff --git a/data/skeletons/lalr1.cc b/data/skeletons/lalr1.cc
index c5d6377f..7b6cc715 100644
--- a/data/skeletons/lalr1.cc
+++ b/data/skeletons/lalr1.cc
@@ -1418,7 +1418,7 @@ b4_dollar_popdef])[]dnl
                      : yylac_stack_.back ());
         // Push the resulting state of the reduction.
         state_type state = yy_lr_goto_state_ (top_state, yyr1_[yyrule]);
-        YYCDEBUG << " G" << state;
+        YYCDEBUG << " G" << int (state);
         yylac_stack_.push_back (state);
       }
   }




reply via email to

[Prev in Thread] Current Thread [Next in Thread]