aboutsummaryrefslogtreecommitdiff
path: root/gdb/m2-exp.y
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/m2-exp.y')
-rw-r--r--gdb/m2-exp.y9
1 files changed, 2 insertions, 7 deletions
diff --git a/gdb/m2-exp.y b/gdb/m2-exp.y
index 9179187..02dc36f 100644
--- a/gdb/m2-exp.y
+++ b/gdb/m2-exp.y
@@ -1036,17 +1036,12 @@ yylex (void)
int
m2_parse (struct parser_state *par_state)
{
- int result;
- struct cleanup *c = make_cleanup_clear_parser_state (&pstate);
-
/* Setting up the parser state. */
+ scoped_restore pstate_restore = make_scoped_restore (&pstate);
gdb_assert (par_state != NULL);
pstate = par_state;
- result = yyparse ();
- do_cleanups (c);
-
- return result;
+ return yyparse ();
}
void