]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
* interps.c (_initialize_interpreter): Remove ability to set
authorKeith Seitz <keiths@redhat.com>
Tue, 13 Aug 2002 16:49:06 +0000 (16:49 +0000)
committerKeith Seitz <keiths@redhat.com>
Tue, 13 Aug 2002 16:49:06 +0000 (16:49 +0000)
        the interpreter. This could really undermine MI clients.
        * top.c (catcher): Don't worry about interpreter changes.

gdb/ChangeLog
gdb/interps.c
gdb/top.c

index 005756d80732b9858f55a284820a7b9b64d10b67..5cd007086d4ca2bf2a350ebccf285e0445a4fb25 100644 (file)
@@ -1,3 +1,9 @@
+2002-08-13  Keith Seitz  <keiths@redhat.com>
+
+       * interps.c (_initialize_interpreter): Remove ability to set
+       the interpreter. This could really undermine MI clients.
+       * top.c (catcher): Don't worry about interpreter changes.
+
 2002-08-12  Keith Seitz  <keiths@redhat.com>
 
        * interps.c (_initialize_interpreter): Add completer function
index 3ec27a8dd7374fa43f47e58c56b1f9f0781713a2..19b108ba3c5bb149ec6aae5c988d199f25027b3e 100644 (file)
@@ -649,17 +649,6 @@ _initialize_interpreter (void)
 {
   struct cmd_list_element *c;
 
-  c = add_set_cmd ("interpreter", class_support,
-                  var_string,
-                  &interpreter_p, "Set the interpreter for gdb.", &setlist);
-  set_cmd_sfunc (c, set_interpreter_cmd);
-  set_cmd_completer (c, interpreter_completer);
-  add_show_from_set (c, &showlist);
-
-  add_cmd ("interpreters", class_support,
-          list_interpreter_cmd,
-          "List the interpreters currently available in gdb.", &infolist);
-
   c = add_cmd ("interpreter-exec", class_support,
               interpreter_exec_cmd,
               "Execute a command in an interpreter.  It takes two arguments:\n\
index 4572e133d7965128805870e9984ad86fca89b305..48b3384d0b72daa370a8852d44822ea3fdaca08c 100644 (file)
--- a/gdb/top.c
+++ b/gdb/top.c
@@ -387,7 +387,6 @@ catcher (catch_exceptions_ftype *func,
   char *saved_error_pre_print;
   char *saved_quit_pre_print;
   struct ui_out *saved_uiout;
-  struct gdb_interpreter *saved_interp;
 
   /* Return value from SIGSETJMP(): enum return_reason if error or
      quit caught, 0 otherwise. */
@@ -410,7 +409,6 @@ catcher (catch_exceptions_ftype *func,
   /* Override the global ``struct ui_out'' builder.  */
 
   saved_uiout = uiout;
-  saved_interp = gdb_current_interpreter ();
   uiout = func_uiout;
 
   /* Prevent error/quit during FUNC from calling cleanups established
@@ -441,24 +439,7 @@ catcher (catch_exceptions_ftype *func,
 
   restore_cleanups (saved_cleanup_chain);
 
-  /*
-    cases:
-    1. interp1 calls using uiout1
-    2. interp1 calls using uiout1 calls using uiout2
-    3. interp1 calls using uiout1 calls interp2 using uiout2
-    4. more?
-    is it enough to note that the interpreter has changed and
-    reset saved_uiout
-   */
-  if (gdb_current_interpreter () == saved_interp)
-    uiout = saved_uiout;
-  else
-    {
-      /* We've changed interpreters under this call.
-        Reset uiout to the current interpreter's uiout
-        and hope for the best. */
-      uiout = gdb_interpreter_ui_out (NULL);
-    }
+  uiout = saved_uiout;
 
   if (mask & RETURN_MASK_QUIT)
     quit_pre_print = saved_quit_pre_print;