[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 6/8] lalr1.cc: always initialize yylval.
From: |
Akim Demaille |
Subject: |
[PATCH 6/8] lalr1.cc: always initialize yylval. |
Date: |
Tue, 6 Nov 2012 17:47:15 +0100 |
* data/lalr1.cc: here.
---
data/lalr1.cc | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/data/lalr1.cc b/data/lalr1.cc
index 4eac635..2fe8d4c 100644
--- a/data/lalr1.cc
+++ b/data/lalr1.cc
@@ -520,7 +520,8 @@ do { \
int yyerrstatus_ = 0;
/// Semantic value of the lookahead.
- semantic_type yylval;
+ static semantic_type yyval_default;
+ semantic_type yylval = yyval_default;
/// Location of the lookahead.
location_type yylloc;
/// The locations where the error started and ended.
--
1.8.0
- [PATCH 0/8] {branch-2.6} more fixes for -Wuninitialized warnings, Akim Demaille, 2012/11/06
- [PATCH 3/8] glr.cc, yacc.c: initialize yylloc properly, Akim Demaille, 2012/11/06
- [PATCH 4/8] yacc.c: also disable -Wuninitialized., Akim Demaille, 2012/11/06
- [PATCH 6/8] lalr1.cc: always initialize yylval.,
Akim Demaille <=
- [PATCH 2/8] yacc.c, glr.c: a better YY_LOCATION_PRINT, Akim Demaille, 2012/11/06
- [PATCH 8/8] tests: calc: modernize the use of locations, Akim Demaille, 2012/11/06
- [PATCH 1/8] yacc.c: simplify initialization, Akim Demaille, 2012/11/06
- [PATCH 5/8] tests: check that C and C++ objects can be linked together., Akim Demaille, 2012/11/06
- [PATCH 7/8] tests: remove useless location initializations, Akim Demaille, 2012/11/06