This removes the last remaining cleanups from go-exp.y.
2017-09-05 Tom Tromey <tom@tromey.com>
* go-exp.y (go_parse): Don't create a cleanup.
+2017-09-05 Tom Tromey <tom@tromey.com>
+
+ * go-exp.y (go_parse): Don't create a cleanup.
+
2017-09-05 Tom Tromey <tom@tromey.com>
* d-exp.y (PrimaryExpression): Use std::string.
int
go_parse (struct parser_state *par_state)
{
- int result;
- struct cleanup *back_to;
-
/* Setting up the parser state. */
scoped_restore pstate_restore = make_scoped_restore (&pstate);
gdb_assert (par_state != NULL);
pstate = par_state;
- /* Note that parsing (within yyparse) freely installs cleanups
- assuming they'll be run here (below). */
- back_to = make_cleanup (null_cleanup, NULL);
-
scoped_restore restore_yydebug = make_scoped_restore (&yydebug,
parser_debug);
popping = 0;
name_obstack.clear ();
- result = yyparse ();
- do_cleanups (back_to);
- return result;
+ return yyparse ();
}
void