Mercurial > hg > octave-nkf
comparison src/input.cc @ 9260:9c2349a51218
properly unmark forced variables
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Tue, 26 May 2009 11:20:40 -0400 |
parents | 1500d0197484 |
children | fddb9f9f724b |
comparison
equal
deleted
inserted
replaced
9259:75c502937d2c | 9260:9c2349a51218 |
---|---|
664 reset_parser (); | 664 reset_parser (); |
665 | 665 |
666 // Save current value of global_command. | 666 // Save current value of global_command. |
667 unwind_protect_ptr (global_command); | 667 unwind_protect_ptr (global_command); |
668 | 668 |
669 // Do this with an unwind-protect cleanup function so that the | |
670 // forced variables will be unmarked in the event of an interrupt. | |
671 symbol_table::scope_id scope = symbol_table::top_scope (); | |
672 unwind_protect::add (symbol_table::unmark_forced_variables, &scope); | |
673 | |
669 // This is the same as yyparse in parse.y. | 674 // This is the same as yyparse in parse.y. |
670 int retval = octave_parse (); | 675 int retval = octave_parse (); |
671 | 676 |
672 if (retval == 0 && global_command) | 677 if (retval == 0 && global_command) |
673 { | 678 { |
684 // global_command = 0; | 689 // global_command = 0; |
685 | 690 |
686 if (octave_completion_matches_called) | 691 if (octave_completion_matches_called) |
687 octave_completion_matches_called = false; | 692 octave_completion_matches_called = false; |
688 } | 693 } |
694 | |
695 // Unmark forced variables. | |
696 unwind_protect::run (); | |
689 | 697 |
690 // Restore previous value of global_command. | 698 // Restore previous value of global_command. |
691 unwind_protect::run (); | 699 unwind_protect::run (); |
692 | 700 |
693 OCTAVE_QUIT; | 701 OCTAVE_QUIT; |