[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 3/9] lalr1.cc: indentation fixes.
From: |
Akim Demaille |
Subject: |
[PATCH 3/9] lalr1.cc: indentation fixes. |
Date: |
Tue, 2 Oct 2012 19:11:08 +0200 |
* data/lalr1.cc (yyparse): here.
Untabify a block of code.
---
data/lalr1.cc | 39 +++++++++++++++++++--------------------
1 file changed, 19 insertions(+), 20 deletions(-)
diff --git a/data/lalr1.cc b/data/lalr1.cc
index 308290a..846aea1 100644
--- a/data/lalr1.cc
+++ b/data/lalr1.cc
@@ -712,20 +712,19 @@ m4_ifdef([b4_lex_param], [, ]b4_lex_param))[;
yyerror_range[1] = yylloc;
if (yyerrstatus_ == 3)
{
- /* If just tried and failed to reuse lookahead token after an
- error, discard it. */
-
- if (yychar <= yyeof_)
- {
- /* Return failure if at end of input. */
- if (yychar == yyeof_)
- YYABORT;
- }
- else
- {
- yydestruct_ ("Error: discarding", yytoken, &yylval, &yylloc);
- yychar = yyempty_;
- }
+ /* If just tried and failed to reuse lookahead token after an
+ error, discard it. */
+ if (yychar <= yyeof_)
+ {
+ /* Return failure if at end of input. */
+ if (yychar == yyeof_)
+ YYABORT;
+ }
+ else
+ {
+ yydestruct_ ("Error: discarding", yytoken, &yylval, &yylloc);
+ yychar = yyempty_;
+ }
}
/* Else will try to reuse lookahead token after shifting the error
@@ -774,7 +773,7 @@ m4_ifdef([b4_lex_param], [, ]b4_lex_param))[;
/* Pop the current state because it cannot handle the error token. */
if (yystate_stack_.height () == 1)
- YYABORT;
+ YYABORT;
yyerror_range[1] = yylocation_stack_[0];
yydestruct_ ("Error: popping",
@@ -824,11 +823,11 @@ m4_ifdef([b4_lex_param], [, ]b4_lex_param))[;
yypop_ (yylen);
while (yystate_stack_.height () != 1)
{
- yydestruct_ ("Cleanup: popping",
- yystos_[yystate_stack_[0]],
- &yysemantic_stack_[0],
- &yylocation_stack_[0]);
- yypop_ ();
+ yydestruct_ ("Cleanup: popping",
+ yystos_[yystate_stack_[0]],
+ &yysemantic_stack_[0],
+ &yylocation_stack_[0]);
+ yypop_ ();
}
return yyresult;
--
1.7.12.2
- [PATCH 0/9] {maint} lalr1.cc: exception safety, Akim Demaille, 2012/10/02
- [PATCH 4/9] lalr1.cc: check exception safety., Akim Demaille, 2012/10/02
- [PATCH 7/9] lalr1.cc: check (and fix) %printer exception safety, Akim Demaille, 2012/10/02
- [PATCH 6/9] lalr1.cc: check (and fix) %initial-action exception safety, Akim Demaille, 2012/10/02
- [PATCH 1/9] tests: minor improvements, Akim Demaille, 2012/10/02
- [PATCH 8/9] lalr1.cc: check exception safety of yyerror, Akim Demaille, 2012/10/02
- [PATCH 5/9] lalr1.cc: fix exception safety, Akim Demaille, 2012/10/02
- [PATCH 2/9] lalr1.cc: don't leave macros define to nothing, Akim Demaille, 2012/10/02
- [PATCH 3/9] lalr1.cc: indentation fixes.,
Akim Demaille <=
- [PATCH 9/9] lalr1.cc: document exception safety, Akim Demaille, 2012/10/02
- Re: [PATCH 0/9] {maint} lalr1.cc: exception safety, Akim Demaille, 2012/10/03