(arc_get_disassembler): Renamed from arc_disassembler.
[deliverable/binutils-gdb.git] / gdb / top.c
index 894e42e920608447c06a11e28ab3803cbfa44256..d958c166f2c673640340ef8562b4943f9fcb3185 100644 (file)
--- a/gdb/top.c
+++ b/gdb/top.c
@@ -1,5 +1,5 @@
 /* Top level stuff for GDB, the GNU debugger.
-   Copyright 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 1994
+   Copyright 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995
    Free Software Foundation, Inc.
 
 This file is part of GDB.
@@ -56,6 +56,10 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.  */
 #include <sys/stat.h>
 #include <ctype.h>
 
+extern void initialize_targets PARAMS ((void));
+
+extern void initialize_utils PARAMS ((void));
+
 /* Prototypes for local functions */
 
 static char * line_completion_function PARAMS ((char *, int, char *, int));
@@ -162,11 +166,13 @@ static void source_cleanup PARAMS ((FILE *));
 #define        GDBINIT_FILENAME        ".gdbinit"
 #endif
 char gdbinit[] = GDBINIT_FILENAME;
+
 int inhibit_gdbinit = 0;
 
-/* Disable windows if non-zero */
+/* If nonzero, and GDB has been configured to be able to use windows,
+   attempt to open them upon startup.  */
 
-int use_windows = 0;           /* Defaults to off for now */
+int use_windows = 1;
 
 /* Version number of GDB, as a string.  */
 
@@ -186,9 +192,7 @@ extern char lang_frame_mismatch_warn[];             /* language.c */
 
 int caution = 1;                       /* Default is yes, sigh. */
 
-/*
- * Define all cmd_list_element's
- */
+/* Define all cmd_list_elements.  */
 
 /* Chain containing all defined commands.  */
 
@@ -399,6 +403,11 @@ void (*disable_breakpoint_hook) PARAMS ((struct breakpoint *bpt));
 
 void (*interactive_hook) PARAMS ((void));
 
+/* Called when the registers have changed, as a hint to a GUI
+   to minimize window update. */
+
+void (*registers_changed_hook) PARAMS ((void));
+
 /* Called when going to wait for the target.  Usually allows the GUI to run
    while waiting for target events.  */
 
@@ -993,7 +1002,7 @@ static char *
 locate_arg (p)
      char *p;
 {
-  while (p = strchr (p, '$'))
+  while ((p = strchr (p, '$')))
     {
       if (strncmp (p, "$arg", 4) == 0 && isdigit (p[4]))
        return p;
@@ -1015,7 +1024,7 @@ insert_args (line)
   /* First we need to know how much memory to allocate for the new line.  */
   save_line = line;
   len = 0;
-  while (p = locate_arg (line))
+  while ((p = locate_arg (line)))
     {
       len += p - line;
       i = p[4] - '0';
@@ -1043,7 +1052,7 @@ insert_args (line)
   /* Save pointer to beginning of new line.  */
   save_line = new_line;
 
-  while (p = locate_arg (line))
+  while ((p = locate_arg (line)))
     {
       int i, len;
 
@@ -1051,7 +1060,8 @@ insert_args (line)
       new_line += p - line;
       i = p[4] - '0';
 
-      if (len = user_args->a[i].len)
+      len = user_args->a[i].len;
+      if (len)
        {
          memcpy (new_line, user_args->a[i].arg, len);
          new_line += len;
@@ -3388,7 +3398,7 @@ End with a line of just \"end\".");
 Definition appears on following lines, one command per line.\n\
 End with a line of just \"end\".\n\
 Use the \"document\" command to give documentation for the new command.\n\
-Commands defined in this way do not take arguments.");
+Commands defined in this way may have up to ten arguments.");
 
 #ifdef __STDC__
   c = add_cmd ("source", class_support, source_command,
This page took 0.025202 seconds and 4 git commands to generate.