Mercurial > hg > octave-lyh
diff src/oct-hist.cc @ 3018:5708b8bb4f06
[project @ 1997-06-03 21:48:05 by jwe]
author | jwe |
---|---|
date | Tue, 03 Jun 1997 21:57:33 +0000 |
parents | f512c16826d1 |
children | 4964d5391acc |
line wrap: on
line diff
--- a/src/oct-hist.cc +++ b/src/oct-hist.cc @@ -64,6 +64,7 @@ #include "oct-hist.h" #include "oct-obj.h" #include "pager.h" +#include "parse.h" #include "sighandlers.h" #include "sysdep.h" #include "toplev.h" @@ -71,8 +72,8 @@ #include "utils.h" #include "variables.h" -// Nonzero means input is coming from temporary history file. -int input_from_tmp_history_file = 0; +// TRUE means input is coming from temporary history file. +bool input_from_tmp_history_file = false; // Where history is saved. static string Vhistory_file; @@ -81,7 +82,7 @@ static int Vhistory_size; // TRUE if we are saving history. -int Vsaving_history; +bool Vsaving_history = true; // Get some default values, possibly reading them from the // environment. @@ -485,10 +486,12 @@ // sense. unwind_protect::begin_frame ("do_edit_history"); + unwind_protect_int (Vecho_executing_commands); - unwind_protect_int (input_from_tmp_history_file); + unwind_protect_bool (input_from_tmp_history_file); + Vecho_executing_commands = ECHO_CMD_LINE; - input_from_tmp_history_file = 1; + input_from_tmp_history_file = true; parse_and_execute (name); @@ -512,10 +515,12 @@ // sense. unwind_protect::begin_frame ("do_run_history"); + unwind_protect_int (Vecho_executing_commands); - unwind_protect_int (input_from_tmp_history_file); + unwind_protect_bool (input_from_tmp_history_file); + Vecho_executing_commands = ECHO_CMD_LINE; - input_from_tmp_history_file = 1; + input_from_tmp_history_file = true; parse_and_execute (name);