This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[commit] Use add_setshow_boolean_cmd


(and delete several long-time #if0ed blocks of code adding unimplemented commands).

committed,
Andrew
2005-02-18  Andrew Cagney  <cagney@gnu.org>

	Use add_setshow_boolean_command through out.  Delete #ifdef 0'ed
	code adding set/show boolean commands.
	* cp-valprint.c, dcache.c, exec.c, gdbtypes.c, infrun.c: Update.
	* monitor.c, p-valprint.c, pa64solib.c, printcmd.c: Update.
	* proc-api.c, remote-mips.c, remote.c, solib.c: Update.
	* somsolib.c, symfile.c, top.c, utils.c, valops.c: Update.
	* valprint.c, win32-nat.c, wince.c, xcoffsolib.c: Update.
	* cli/cli-cmds.c: Update.

Index: cp-valprint.c
===================================================================
RCS file: /cvs/src/src/gdb/cp-valprint.c,v
retrieving revision 1.38
diff -p -u -r1.38 cp-valprint.c
--- cp-valprint.c	11 Feb 2005 04:05:45 -0000	1.38
+++ cp-valprint.c	18 Feb 2005 15:16:25 -0000
@@ -810,26 +810,29 @@ cp_print_hpacc_virtual_table_entries (st
 void
 _initialize_cp_valprint (void)
 {
-  deprecated_add_show_from_set
-    (add_set_cmd ("static-members", class_support, var_boolean,
-		  (char *) &static_field_print,
-		  "Set printing of C++ static members.",
-		  &setprintlist),
-     &showprintlist);
+  add_setshow_boolean_cmd ("static-members", class_support,
+			   &static_field_print, _("\
+Set printing of C++ static members."), _("\
+Show printing of C++ static members."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setprintlist, &showprintlist);
   /* Turn on printing of static fields.  */
   static_field_print = 1;
 
-  deprecated_add_show_from_set
-    (add_set_cmd ("vtbl", class_support, var_boolean, (char *) &vtblprint,
-		  "Set printing of C++ virtual function tables.",
-		  &setprintlist),
-     &showprintlist);
+  add_setshow_boolean_cmd ("vtbl", class_support, &vtblprint, _("\
+Set printing of C++ virtual function tables."), _("\
+Show printing of C++ virtual function tables."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setprintlist, &showprintlist);
 
-  deprecated_add_show_from_set
-    (add_set_cmd ("object", class_support, var_boolean, (char *) &objectprint,
-	      "Set printing of object's derived type based on vtable info.",
-		  &setprintlist),
-     &showprintlist);
+  add_setshow_boolean_cmd ("object", class_support, &objectprint, _("\
+Set printing of object's derived type based on vtable info."), _("\
+Show printing of object's derived type based on vtable info."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setprintlist, &showprintlist);
 
   /* Give people the defaults which they are used to.  */
   objectprint = 0;
Index: dcache.c
===================================================================
RCS file: /cvs/src/src/gdb/dcache.c,v
retrieving revision 1.21
diff -p -u -r1.21 dcache.c
--- dcache.c	15 Feb 2005 15:49:08 -0000	1.21
+++ dcache.c	18 Feb 2005 15:16:26 -0000
@@ -585,18 +585,18 @@ dcache_info (char *exp, int tty)
 void
 _initialize_dcache (void)
 {
-  deprecated_add_show_from_set
-    (add_set_cmd ("remotecache", class_support, var_boolean,
-		  (char *) &dcache_enabled_p,
-		  "\
-Set cache use for remote targets.\n\
+  add_setshow_boolean_cmd ("remotecache", class_support,
+			   &dcache_enabled_p, _("\
+Set cache use for remote targets."), _("\
+Show cache use for remote targets."), _("\
 When on, use data caching for remote targets.  For many remote targets\n\
 this option can offer better throughput for reading target memory.\n\
 Unfortunately, gdb does not currently know anything about volatile\n\
 registers and thus data caching will produce incorrect results with\n\
-volatile registers are in use.  By default, this option is off.",
-		  &setlist),
-     &showlist);
+volatile registers are in use.  By default, this option is off."),
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
 
   add_info ("dcache", dcache_info,
 	    _("Print information on the dcache performance."));
Index: exec.c
===================================================================
RCS file: /cvs/src/src/gdb/exec.c,v
retrieving revision 1.49
diff -p -u -r1.49 exec.c
--- exec.c	15 Feb 2005 15:49:09 -0000	1.49
+++ exec.c	18 Feb 2005 15:16:26 -0000
@@ -742,11 +742,12 @@ This can be used if the exec file does n
 file itself are wrong.  Each section must be changed separately.  The\n\
 ``info files'' command lists all the sections and their addresses."));
 
-  deprecated_add_show_from_set
-    (add_set_cmd ("write", class_support, var_boolean, (char *) &write_files,
-		  "Set writing into executable and core files.",
-		  &setlist),
-     &showlist);
+  add_setshow_boolean_cmd ("write", class_support, &write_files, _("\
+Set writing into executable and core files."), _("\
+Show writing into executable and core files."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
 
   add_target (&exec_ops);
 }
Index: gdbtypes.c
===================================================================
RCS file: /cvs/src/src/gdb/gdbtypes.c,v
retrieving revision 1.96
diff -p -u -r1.96 gdbtypes.c
--- gdbtypes.c	12 Feb 2005 00:39:19 -0000	1.96
+++ gdbtypes.c	18 Feb 2005 15:16:27 -0000
@@ -3252,11 +3252,13 @@ build_gdbtypes (void)
 	       "bool", (struct objfile *) NULL);
 
   /* Add user knob for controlling resolution of opaque types */
-  deprecated_add_show_from_set
-    (add_set_cmd ("opaque-type-resolution", class_support, var_boolean, (char *) &opaque_type_resolution,
-		  "Set resolution of opaque struct/class/union types (if set before loading symbols).",
-		  &setlist),
-     &showlist);
+  add_setshow_boolean_cmd ("opaque-type-resolution", class_support,
+			   &opaque_type_resolution, _("\
+Set resolution of opaque struct/class/union types (if set before loading symbols)."), _("\
+Show resolution of opaque struct/class/union types (if set before loading symbols)."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
   opaque_type_resolution = 1;
 
   /* Build SIMD types.  */
Index: infrun.c
===================================================================
RCS file: /cvs/src/src/gdb/infrun.c,v
retrieving revision 1.194
diff -p -u -r1.194 infrun.c
--- infrun.c	15 Feb 2005 15:49:11 -0000	1.194
+++ infrun.c	18 Feb 2005 15:16:27 -0000
@@ -3929,13 +3929,15 @@ step == scheduler locked during every si
   set_cmd_sfunc (c, set_schedlock_func);	/* traps on target vector */
   deprecated_add_show_from_set (c, &showlist);
 
-  c = add_set_cmd ("step-mode", class_run,
-		   var_boolean, (char *) &step_stop_if_no_debug,
-		   "Set mode of the step operation. When set, doing a step over a\n\
-function without debug line information will stop at the first\n\
-instruction of that function. Otherwise, the function is skipped and\n\
-the step command stops at a different source line.", &setlist);
-  deprecated_add_show_from_set (c, &showlist);
+  add_setshow_boolean_cmd ("step-mode", class_run, &step_stop_if_no_debug, _("\
+Set mode of the step operation."), _("\
+Show mode of the step operation."), _("\
+When set, doing a step over a function without debug line information\n\
+will stop at the first instruction of that function. Otherwise, the\n\
+function is skipped and the step command stops at a different source line."),
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
 
   /* ptid initializations */
   null_ptid = ptid_build (0, 0, 0);
Index: monitor.c
===================================================================
RCS file: /cvs/src/src/gdb/monitor.c,v
retrieving revision 1.58
diff -p -u -r1.58 monitor.c
--- monitor.c	12 Feb 2005 00:39:20 -0000	1.58
+++ monitor.c	18 Feb 2005 15:16:27 -0000
@@ -2295,13 +2295,13 @@ void
 _initialize_remote_monitors (void)
 {
   init_base_monitor_ops ();
-  deprecated_add_show_from_set
-    (add_set_cmd ("hash", no_class, var_boolean,
-		  (char *) &hashmark,
-		  "Set display of activity while downloading a file.\n\
-When enabled, a hashmark \'#\' is displayed.",
-		  &setlist),
-     &showlist);
+  add_setshow_boolean_cmd ("hash", no_class, &hashmark, _("\
+Set display of activity while downloading a file."), _("\
+Show display of activity while downloading a file."), _("\
+When enabled, a hashmark \'#\' is displayed."),
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
 
   deprecated_add_show_from_set
     (add_set_cmd ("monitor", no_class, var_zinteger,
Index: p-valprint.c
===================================================================
RCS file: /cvs/src/src/gdb/p-valprint.c,v
retrieving revision 1.35
diff -p -u -r1.35 p-valprint.c
--- p-valprint.c	14 Feb 2005 14:37:38 -0000	1.35
+++ p-valprint.c	18 Feb 2005 15:16:28 -0000
@@ -1107,12 +1107,13 @@ extern initialize_file_ftype _initialize
 void
 _initialize_pascal_valprint (void)
 {
-  deprecated_add_show_from_set
-    (add_set_cmd ("pascal_static-members", class_support, var_boolean,
-		  (char *) &pascal_static_field_print,
-		  "Set printing of pascal static members.",
-		  &setprintlist),
-     &showprintlist);
+  add_setshow_boolean_cmd ("pascal_static-members", class_support,
+			   &pascal_static_field_print, _("\
+Set printing of pascal static members."), _("\
+Show printing of pascal static members."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setprintlist, &showprintlist);
   /* Turn on printing of static fields.  */
   pascal_static_field_print = 1;
 
Index: pa64solib.c
===================================================================
RCS file: /cvs/src/src/gdb/pa64solib.c,v
retrieving revision 1.30
diff -p -u -r1.30 pa64solib.c
--- pa64solib.c	15 Feb 2005 15:49:14 -0000	1.30
+++ pa64solib.c	18 Feb 2005 15:16:30 -0000
@@ -889,16 +889,17 @@ _initialize_pa64_solib (void)
   add_info ("sharedlibrary", pa64_sharedlibrary_info_command,
 	    _("Status of loaded shared object libraries."));
 
-  deprecated_add_show_from_set
-    (add_set_cmd ("auto-solib-add", class_support, var_boolean,
-		  (char *) &auto_solib_add,
-		  "Set autoloading of shared library symbols.\n\
+  add_setshow_boolean_cmd ("auto-solib-add", class_support,
+			   &auto_solib_add, _("\
+Set autoloading of shared library symbols."), _("\
+Show autoloading of shared library symbols."), _("\
 If \"on\", symbols from all shared object libraries will be loaded\n\
 automatically when the inferior begins execution, when the dynamic linker\n\
 informs gdb that a new library has been loaded, or when attaching to the\n\
-inferior.  Otherwise, symbols must be loaded manually, using `sharedlibrary'.",
-		  &setlist),
-     &showlist);
+inferior.  Otherwise, symbols must be loaded manually, using `sharedlibrary'."),
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
 
   deprecated_add_show_from_set
     (add_set_cmd ("auto-solib-limit", class_support, var_zinteger,
Index: printcmd.c
===================================================================
RCS file: /cvs/src/src/gdb/printcmd.c,v
retrieving revision 1.91
diff -p -u -r1.91 printcmd.c
--- printcmd.c	15 Feb 2005 15:49:14 -0000	1.91
+++ printcmd.c	18 Feb 2005 15:16:31 -0000
@@ -2134,12 +2134,13 @@ environment, the value is printed in its
        "Set the largest offset that will be printed in <symbol+1234> form.",
 		  &setprintlist),
      &showprintlist);
-  deprecated_add_show_from_set
-    (add_set_cmd ("symbol-filename", no_class, var_boolean,
-		  (char *) &print_symbol_filename, "\
-Set printing of source filename and line number with <symbol>.",
-		  &setprintlist),
-     &showprintlist);
+  add_setshow_boolean_cmd ("symbol-filename", no_class,
+			   &print_symbol_filename, _("\
+Set printing of source filename and line number with <symbol>."), _("\
+Show printing of source filename and line number with <symbol>."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setprintlist, &showprintlist);
 
   /* For examine/instruction a single byte quantity is specified as
      the data.  This avoids problems with value_at_lazy() requiring a
Index: proc-api.c
===================================================================
RCS file: /cvs/src/src/gdb/proc-api.c,v
retrieving revision 1.21
diff -p -u -r1.21 proc-api.c
--- proc-api.c	17 Feb 2005 17:11:03 -0000	1.21
+++ proc-api.c	18 Feb 2005 15:16:31 -0000
@@ -780,13 +780,12 @@ _initialize_proc_api (void)
 {
   struct cmd_list_element *c;
 
-  c = add_set_cmd ("procfs-trace", no_class,
-		   var_boolean, (char *) &procfs_trace, 
-		   "Set tracing for /proc api calls.\n", &setlist);
-
-  deprecated_add_show_from_set (c, &showlist);
-  set_cmd_sfunc (c, set_procfs_trace_cmd);
-  set_cmd_completer (c, filename_completer);
+  add_setshow_boolean_cmd ("procfs-trace", no_class, &procfs_trace, _("\ 
+Set tracing for /proc api calls."), _("\
+Show tracing for /proc api calls."), NULL,
+			   set_procfs_trace_cmd,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
 
   add_setshow_filename_cmd ("procfs-file", no_class, &procfs_filename, _("\
 Set filename for /proc tracefile."), _("\
Index: remote-mips.c
===================================================================
RCS file: /cvs/src/src/gdb/remote-mips.c,v
retrieving revision 1.62
diff -p -u -r1.62 remote-mips.c
--- remote-mips.c	15 Feb 2005 15:49:15 -0000	1.62
+++ remote-mips.c	18 Feb 2005 15:16:32 -0000
@@ -3415,11 +3415,11 @@ ignored.)",
   add_com ("pmon <command>", class_obscure, pmon_command,
 	   _("Send a packet to PMON (must be in debug mode)."));
 
-  deprecated_add_show_from_set
-    (add_set_cmd ("mask-address", no_class,
-		  var_boolean, &mask_address_p, "\
-Set zeroing of upper 32 bits of 64-bit addresses when talking to PMON targets.\n\
-Use \"on\" to enable the masking and \"off\" to disable it.\n",
-		  &setlist),
-     &showlist);
+  add_setshow_boolean_cmd ("mask-address", no_class, &mask_address_p, _("\
+Set zeroing of upper 32 bits of 64-bit addresses when talking to PMON targets."), _("\
+Show zeroing of upper 32 bits of 64-bit addresses when talking to PMON targets."), _("\
+Use \"on\" to enable the masking and \"off\" to disable it."),
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
 }
Index: remote.c
===================================================================
RCS file: /cvs/src/src/gdb/remote.c,v
retrieving revision 1.172
diff -p -u -r1.172 remote.c
--- remote.c	17 Feb 2005 13:49:55 -0000	1.172
+++ remote.c	18 Feb 2005 15:16:36 -0000
@@ -5688,15 +5688,6 @@ in a memory packet.\n",
 			 show_remote_protocol_binary_download_cmd,
 			 &remote_set_cmdlist, &remote_show_cmdlist,
 			 1);
-#if 0
-  /* XXXX - should ``set remotebinarydownload'' be retained for
-     compatibility.  */
-  deprecated_add_show_from_set
-    (add_set_cmd ("remotebinarydownload", no_class,
-		  var_boolean, (char *) &remote_binary_download,
-		  "Set binary downloads.\n", &setlist),
-     &showlist);
-#endif
 
   add_packet_config_cmd (&remote_protocol_vcont,
 			 "vCont", "verbose-resume",
Index: solib.c
===================================================================
RCS file: /cvs/src/src/gdb/solib.c,v
retrieving revision 1.76
diff -p -u -r1.76 solib.c
--- solib.c	17 Feb 2005 17:11:03 -0000	1.76
+++ solib.c	18 Feb 2005 15:16:36 -0000
@@ -900,16 +900,17 @@ _initialize_solib (void)
   add_com ("nosharedlibrary", class_files, no_shared_libraries,
 	   _("Unload all shared object library symbols."));
 
-  deprecated_add_show_from_set
-    (add_set_cmd ("auto-solib-add", class_support, var_boolean,
-		  (char *) &auto_solib_add,
-		  "Set autoloading of shared library symbols.\n\
+  add_setshow_boolean_cmd ("auto-solib-add", class_support,
+			   &auto_solib_add, _("\
+Set autoloading of shared library symbols."), _("\
+Show autoloading of shared library symbols."), _("\
 If \"on\", symbols from all shared object libraries will be loaded\n\
 automatically when the inferior begins execution, when the dynamic linker\n\
 informs gdb that a new library has been loaded, or when attaching to the\n\
-inferior.  Otherwise, symbols must be loaded manually, using `sharedlibrary'.",
-		  &setlist),
-     &showlist);
+inferior.  Otherwise, symbols must be loaded manually, using `sharedlibrary'."),
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
 
   add_setshow_filename_cmd ("solib-absolute-prefix", class_support,
 			    &solib_absolute_prefix, _("\
Index: somsolib.c
===================================================================
RCS file: /cvs/src/src/gdb/somsolib.c,v
retrieving revision 1.43
diff -p -u -r1.43 somsolib.c
--- somsolib.c	15 Feb 2005 15:49:20 -0000	1.43
+++ somsolib.c	18 Feb 2005 15:16:40 -0000
@@ -1557,16 +1557,17 @@ _initialize_som_solib (void)
   add_info ("sharedlibrary", som_sharedlibrary_info_command,
 	    _("Status of loaded shared object libraries."));
 
-  deprecated_add_show_from_set
-    (add_set_cmd ("auto-solib-add", class_support, var_boolean,
-		  (char *) &auto_solib_add,
-		  "Set autoloading of shared library symbols.\n\
+  add_setshow_boolean_cmd ("auto-solib-add", class_support,
+			   &auto_solib_add, _("\
+Set autoloading of shared library symbols."), _("\
+Show autoloading of shared library symbols."), _("\
 If \"on\", symbols from all shared object libraries will be loaded\n\
 automatically when the inferior begins execution, when the dynamic linker\n\
 informs gdb that a new library has been loaded, or when attaching to the\n\
-inferior.  Otherwise, symbols must be loaded manually, using `sharedlibrary'.",
-		  &setlist),
-     &showlist);
+inferior.  Otherwise, symbols must be loaded manually, using `sharedlibrary'."),
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
 
   deprecated_add_show_from_set
     (add_set_cmd ("auto-solib-limit", class_support, var_zinteger,
Index: symfile.c
===================================================================
RCS file: /cvs/src/src/gdb/symfile.c,v
retrieving revision 1.151
diff -p -u -r1.151 symfile.c
--- symfile.c	17 Feb 2005 15:00:31 -0000	1.151
+++ symfile.c	18 Feb 2005 15:16:42 -0000
@@ -3560,12 +3560,13 @@ Dynamically load FILE into the running p
 for access from GDB."), &cmdlist);
   set_cmd_completer (c, filename_completer);
 
-  deprecated_add_show_from_set
-    (add_set_cmd ("symbol-reloading", class_support, var_boolean,
-		  (char *) &symbol_reloading,
-	    "Set dynamic symbol table reloading multiple times in one run.",
-		  &setlist),
-     &showlist);
+  add_setshow_boolean_cmd ("symbol-reloading", class_support,
+			   &symbol_reloading, _("\
+Set dynamic symbol table reloading multiple times in one run."), _("\
+Show dynamic symbol table reloading multiple times in one run."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
 
   add_prefix_cmd ("overlay", class_support, overlay_command,
 		  _("Commands for debugging overlays."), &overlaylist,
Index: top.c
===================================================================
RCS file: /cvs/src/src/gdb/top.c,v
retrieving revision 1.99
diff -p -u -r1.99 top.c
--- top.c	15 Feb 2005 15:49:22 -0000	1.99
+++ top.c	18 Feb 2005 15:16:42 -0000
@@ -1385,21 +1385,25 @@ Don't repeat this command.\n\
 Primarily used inside of user-defined commands that should not be repeated when\n\
 hitting return."));
 
-  c = add_set_cmd ("editing", class_support, var_boolean, (char *) &async_command_editing_p,
-		   "Set editing of command lines as they are typed.\n\
+  add_setshow_boolean_cmd ("editing", class_support,
+			   &async_command_editing_p, _("\
+Set editing of command lines as they are typed."), _("\
+Show editing of command lines as they are typed."), _("\
 Use \"on\" to enable the editing, and \"off\" to disable it.\n\
 Without an argument, command line editing is enabled.  To edit, use\n\
-EMACS-like or VI-like commands like control-P or ESC.", &setlist);
-
-  deprecated_add_show_from_set (c, &showlist);
-  set_cmd_sfunc (c, set_async_editing_command);
-
-  deprecated_add_show_from_set
-    (add_set_cmd ("save", no_class, var_boolean, (char *) &write_history_p,
-		  "Set saving of the history record on exit.\n\
+EMACS-like or VI-like commands like control-P or ESC."),
+			   set_async_editing_command,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
+
+  add_setshow_boolean_cmd ("save", no_class, &write_history_p, _("\
+Set saving of the history record on exit."), _("\
+Show saving of the history record on exit."), _("\
 Use \"on\" to enable the saving, and \"off\" to disable it.\n\
-Without an argument, saving is enabled.", &sethistlist),
-     &showhistlist);
+Without an argument, saving is enabled."),
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &sethistlist, &showhistlist);
 
   c = add_set_cmd ("size", no_class, var_integer, (char *) &history_size,
 		   "Set the size of the command history,\n\
@@ -1414,12 +1418,12 @@ ie. the number of previous commands to k
   set_cmd_completer (c, filename_completer);
   deprecated_add_show_from_set (c, &showhistlist);
 
-  deprecated_add_show_from_set
-    (add_set_cmd ("confirm", class_support, var_boolean,
-		  (char *) &caution,
-		  "Set whether to confirm potentially dangerous operations.",
-		  &setlist),
-     &showlist);
+  add_setshow_boolean_cmd ("confirm", class_support, &caution, _("\
+Set whether to confirm potentially dangerous operations."), _("\
+Show whether to confirm potentially dangerous operations."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
 
   c = add_set_cmd ("annotate", class_obscure, var_zinteger,
 		   (char *) &annotation_level, "Set annotation_level.\n\
@@ -1429,11 +1433,14 @@ ie. the number of previous commands to k
   deprecated_add_show_from_set (c, &showlist);
   set_cmd_sfunc (c, set_async_annotation_level);
 
-  deprecated_add_show_from_set
-    (add_set_cmd ("exec-done-display", class_support, var_boolean, (char *) &exec_done_display_p,
-		  "Set notification of completion for asynchronous execution commands.\n\
-Use \"on\" to enable the notification, and \"off\" to disable it.", &setlist),
-     &showlist);
+  add_setshow_boolean_cmd ("exec-done-display", class_support,
+			   &exec_done_display_p, _("\
+Set notification of completion for asynchronous execution commands."), _("\
+Show notification of completion for asynchronous execution commands."), _("\
+Use \"on\" to enable the notification, and \"off\" to disable it."),
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
 }
 
 void
Index: utils.c
===================================================================
RCS file: /cvs/src/src/gdb/utils.c,v
retrieving revision 1.154
diff -p -u -r1.154 utils.c
--- utils.c	15 Feb 2005 15:49:23 -0000	1.154
+++ utils.c	18 Feb 2005 15:16:43 -0000
@@ -2459,16 +2459,20 @@ initialize_utils (void)
 
   init_page_info ();
 
-  deprecated_add_show_from_set
-    (add_set_cmd ("demangle", class_support, var_boolean,
-		  (char *) &demangle,
-		  "Set demangling of encoded C++/ObjC names when displaying symbols.",
-		  &setprintlist), &showprintlist);
-
-  deprecated_add_show_from_set
-    (add_set_cmd ("pagination", class_support,
-		  var_boolean, (char *) &pagination_enabled,
-		  "Set state of pagination.", &setlist), &showlist);
+  add_setshow_boolean_cmd ("demangle", class_support, &demangle, _("\
+Set demangling of encoded C++/ObjC names when displaying symbols."), _("\
+Show demangling of encoded C++/ObjC names when displaying symbols."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setprintlist, &showprintlist);
+
+  add_setshow_boolean_cmd ("pagination", class_support,
+			   &pagination_enabled, _("\
+Set state of pagination."), _("\
+Show state of pagination."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
 
   if (xdb_commands)
     {
@@ -2478,17 +2482,20 @@ initialize_utils (void)
 	       _("Disable pagination"));
     }
 
-  deprecated_add_show_from_set
-    (add_set_cmd ("sevenbit-strings", class_support, var_boolean,
-		  (char *) &sevenbit_strings,
-		  "Set printing of 8-bit characters in strings as \\nnn.",
-		  &setprintlist), &showprintlist);
-
-  deprecated_add_show_from_set
-    (add_set_cmd ("asm-demangle", class_support, var_boolean,
-		  (char *) &asm_demangle,
-		  "Set demangling of C++/ObjC names in disassembly listings.",
-		  &setprintlist), &showprintlist);
+  add_setshow_boolean_cmd ("sevenbit-strings", class_support,
+			   &sevenbit_strings, _("\
+Set printing of 8-bit characters in strings as \\nnn."), _("\
+Show printing of 8-bit characters in strings as \\nnn."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setprintlist, &showprintlist);
+
+  add_setshow_boolean_cmd ("asm-demangle", class_support, &asm_demangle, _("\
+Set demangling of C++/ObjC names in disassembly listings."), _("\
+Show demangling of C++/ObjC names in disassembly listings."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setprintlist, &showprintlist);
 }
 
 /* Machine specific function to handle SIGWINCH signal. */
Index: valops.c
===================================================================
RCS file: /cvs/src/src/gdb/valops.c,v
retrieving revision 1.153
diff -p -u -r1.153 valops.c
--- valops.c	11 Feb 2005 18:13:54 -0000	1.153
+++ valops.c	18 Feb 2005 15:16:43 -0000
@@ -2833,18 +2833,12 @@ cast_into_complex (struct type *type, st
 void
 _initialize_valops (void)
 {
-#if 0
-  deprecated_add_show_from_set
-    (add_set_cmd ("abandon", class_support, var_boolean, (char *) &auto_abandon,
-		  "Set automatic abandonment of expressions upon failure.",
-		  &setlist),
-     &showlist);
-#endif
-
-  deprecated_add_show_from_set
-    (add_set_cmd ("overload-resolution", class_support, var_boolean, (char *) &overload_resolution,
-		  "Set overload resolution in evaluating C++ functions.",
-		  &setlist),
-     &showlist);
+  add_setshow_boolean_cmd ("overload-resolution", class_support,
+			   &overload_resolution, _("\
+Set overload resolution in evaluating C++ functions."), _("\
+Show overload resolution in evaluating C++ functions."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
   overload_resolution = 1;
 }
Index: valprint.c
===================================================================
RCS file: /cvs/src/src/gdb/valprint.c,v
retrieving revision 1.47
diff -p -u -r1.47 valprint.c
--- valprint.c	15 Feb 2005 15:49:23 -0000	1.47
+++ valprint.c	18 Feb 2005 15:16:44 -0000
@@ -1212,12 +1212,12 @@ _initialize_valprint (void)
 		  &setprintlist),
      &showprintlist);
 
-  deprecated_add_show_from_set
-    (add_set_cmd ("null-stop", no_class, var_boolean,
-		  (char *) &stop_print_at_null,
-		  "Set printing of char arrays to stop at first null char.",
-		  &setprintlist),
-     &showprintlist);
+  add_setshow_boolean_cmd ("null-stop", no_class, &stop_print_at_null, _("\
+Set printing of char arrays to stop at first null char."), _("\
+Show printing of char arrays to stop at first null char."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setprintlist, &showprintlist);
 
   deprecated_add_show_from_set
     (add_set_cmd ("repeats", no_class, var_uinteger,
@@ -1227,31 +1227,33 @@ _initialize_valprint (void)
 		  &setprintlist),
      &showprintlist);
 
-  deprecated_add_show_from_set
-    (add_set_cmd ("pretty", class_support, var_boolean,
-		  (char *) &prettyprint_structs,
-		  "Set prettyprinting of structures.",
-		  &setprintlist),
-     &showprintlist);
-
-  deprecated_add_show_from_set
-    (add_set_cmd ("union", class_support, var_boolean, (char *) &unionprint,
-		  "Set printing of unions interior to structures.",
-		  &setprintlist),
-     &showprintlist);
-
-  deprecated_add_show_from_set
-    (add_set_cmd ("array", class_support, var_boolean,
-		  (char *) &prettyprint_arrays,
-		  "Set prettyprinting of arrays.",
-		  &setprintlist),
-     &showprintlist);
-
-  deprecated_add_show_from_set
-    (add_set_cmd ("address", class_support, var_boolean, (char *) &addressprint,
-		  "Set printing of addresses.",
-		  &setprintlist),
-     &showprintlist);
+  add_setshow_boolean_cmd ("pretty", class_support, &prettyprint_structs, _("\
+Set prettyprinting of structures."), _("\
+Show prettyprinting of structures."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setprintlist, &showprintlist);
+
+  add_setshow_boolean_cmd ("union", class_support, &unionprint, _("\
+Set printing of unions interior to structures."), _("\
+Show printing of unions interior to structures."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setprintlist, &showprintlist);
+
+  add_setshow_boolean_cmd ("array", class_support, &prettyprint_arrays, _("\
+Set prettyprinting of arrays."), _("\
+Show prettyprinting of arrays."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setprintlist, &showprintlist);
+
+  add_setshow_boolean_cmd ("address", class_support, &addressprint, _("\
+Set printing of addresses."), _("\
+Show printing of addresses."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setprintlist, &showprintlist);
 
   c = add_set_cmd ("input-radix", class_support, var_uinteger,
 		   (char *) &input_radix,
Index: win32-nat.c
===================================================================
RCS file: /cvs/src/src/gdb/win32-nat.c,v
retrieving revision 1.107
diff -p -u -r1.107 win32-nat.c
--- win32-nat.c	15 Feb 2005 15:49:23 -0000	1.107
+++ win32-nat.c	18 Feb 2005 15:16:45 -0000
@@ -2123,54 +2123,55 @@ _initialize_win32_nat (void)
 
   add_com_alias ("sharedlibrary", "dll-symbols", class_alias, 1);
 
-  deprecated_add_show_from_set
-    (add_set_cmd ("shell", class_support, var_boolean,
-		  (char *) &useshell,
-		  "Set use of shell to start subprocess.",
-		  &setlist),
-     &showlist);
-
-  deprecated_add_show_from_set
-    (add_set_cmd ("new-console", class_support, var_boolean,
-		  (char *) &new_console,
-		  "Set creation of new console when creating child process.",
-		  &setlist),
-     &showlist);
-
-  deprecated_add_show_from_set
-    (add_set_cmd ("new-group", class_support, var_boolean,
-		  (char *) &new_group,
-		  "Set creation of new group when creating child process.",
-		  &setlist),
-     &showlist);
-
-  deprecated_add_show_from_set
-    (add_set_cmd ("debugexec", class_support, var_boolean,
-		  (char *) &debug_exec,
-		  "Set whether to display execution in child process.",
-		  &setlist),
-     &showlist);
-
-  deprecated_add_show_from_set
-    (add_set_cmd ("debugevents", class_support, var_boolean,
-		  (char *) &debug_events,
-		  "Set whether to display kernel events in child process.",
-		  &setlist),
-     &showlist);
-
-  deprecated_add_show_from_set
-    (add_set_cmd ("debugmemory", class_support, var_boolean,
-		  (char *) &debug_memory,
-		  "Set whether to display memory accesses in child process.",
-		  &setlist),
-     &showlist);
-
-  deprecated_add_show_from_set
-    (add_set_cmd ("debugexceptions", class_support, var_boolean,
-		  (char *) &debug_exceptions,
-		  "Set whether to display kernel exceptions in child process.",
-		  &setlist),
-     &showlist);
+  add_setshow_boolean_cmd ("shell", class_support, &useshell, _("\
+Set use of shell to start subprocess."), _("\
+Show use of shell to start subprocess."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
+
+  add_setshow_boolean_cmd ("new-console", class_support, &new_console, _("\
+Set creation of new console when creating child process."), _("\
+Show creation of new console when creating child process."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
+
+  add_setshow_boolean_cmd ("new-group", class_support, &new_group, _("\
+Set creation of new group when creating child process."), _("\
+Show creation of new group when creating child process."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
+
+  add_setshow_boolean_cmd ("debugexec", class_support, &debug_exec, _("\
+Set whether to display execution in child process."), _("\
+Show whether to display execution in child process."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
+
+  add_setshow_boolean_cmd ("debugevents", class_support, &debug_events, _("\
+Set whether to display kernel events in child process."), _("\
+Show whether to display kernel events in child process."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
+
+  add_setshow_boolean_cmd ("debugmemory", class_support, &debug_memory, _("\
+Set whether to display memory accesses in child process."), _("\
+Show whether to display memory accesses in child process."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
+
+  add_setshow_boolean_cmd ("debugexceptions", class_support,
+			   &debug_exceptions, _("\
+Set whether to display kernel exceptions in child process."), _("\
+Show whether to display kernel exceptions in child process."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
 
   add_info ("dll", info_dll_command, _("Status of loaded DLLs."));
   add_info_alias ("sharedlibrary", "dll", 1);
Index: wince.c
===================================================================
RCS file: /cvs/src/src/gdb/wince.c,v
retrieving revision 1.40
diff -p -u -r1.40 wince.c
--- wince.c	17 Feb 2005 15:00:32 -0000	1.40
+++ wince.c	18 Feb 2005 15:16:46 -0000
@@ -2038,51 +2038,44 @@ Show how to upload executables to remote
 				   &setlist, &showlist);
   set_upload_type (NULL, 0);
 
-  deprecated_add_show_from_set
-    (add_set_cmd ((char *) "debugexec", 
-		  class_support, var_boolean,
-		  (char *) &debug_exec,
-		  (char *) "\
-Set whether to display execution in child process.",
-		  &setlist),
-     &showlist);
-
-  deprecated_add_show_from_set
-    (add_set_cmd ((char *) "remoteaddhost", 
-		  class_support, var_boolean,
-		  (char *) &remote_add_host,
-		  (char *) "\
+  add_setshow_boolean_cmd ("debugexec", class_support, &debug_exec, _("\
+Set whether to display execution in child process."), _("\
+Show whether to display execution in child process."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
+
+  add_setshow_boolean_cmd ("remoteaddhost", class_support,
+			   &remote_add_host, _("\
 Set whether to add this host to remote stub arguments for\n\
-debugging over a network.", 
-		  &setlist),
-     &showlist);
-
-  deprecated_add_show_from_set
-    (add_set_cmd ((char *) "debugevents", 
-		  class_support, var_boolean,
-		  (char *) &debug_events,
-		  (char *) "\
-Set whether to display kernel events in child process.",
-		  &setlist),
-     &showlist);
-
-  deprecated_add_show_from_set
-    (add_set_cmd ((char *) "debugmemory", 
-		  class_support, var_boolean,
-		  (char *) &debug_memory,
-		  (char *) "\
-Set whether to display memory accesses in child process.",
-		  &setlist),
-     &showlist);
-
-  deprecated_add_show_from_set 
-    (add_set_cmd ((char *) "debugexceptions", 
-		  class_support, var_boolean,
-		  (char *) &debug_exceptions,
-		  (char *) "\
-Set whether to display kernel exceptions in child process.",
-		  &setlist),
-     &showlist);
+debugging over a network."), _("\
+Show whether to add this host to remote stub arguments for\n\
+debugging over a network."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
+
+  add_setshow_boolean_cmd ("debugevents", class_support, &debug_events, _("\
+Set whether to display kernel events in child process."), _("\
+Show whether to display kernel events in child process."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
+
+  add_setshow_boolean_cmd ("debugmemory", class_support, &debug_memory, _("\
+Set whether to display memory accesses in child process."), _("\
+Show whether to display memory accesses in child process."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
+
+  add_setshow_boolean_cmd ("debugexceptions", class_support,
+			   &debug_exceptions, _("\
+Set whether to display kernel exceptions in child process."), _("\
+Show whether to display kernel exceptions in child process."), NULL,
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
 
   add_target (&deprecated_child_ops);
 }
Index: xcoffsolib.c
===================================================================
RCS file: /cvs/src/src/gdb/xcoffsolib.c,v
retrieving revision 1.16
diff -p -u -r1.16 xcoffsolib.c
--- xcoffsolib.c	15 Feb 2005 15:49:24 -0000	1.16
+++ xcoffsolib.c	18 Feb 2005 15:16:46 -0000
@@ -183,14 +183,15 @@ _initialize_xcoffsolib (void)
   add_info ("sharedlibrary", solib_info,
 	    _("Status of loaded shared object libraries"));
 
-  deprecated_add_show_from_set
-    (add_set_cmd ("auto-solib-add", class_support, var_boolean,
-		  (char *) &auto_solib_add,
-		  "Set autoloading of shared library symbols.\n\
+  add_setshow_boolean_cmd ("auto-solib-add", class_support,
+			   &auto_solib_add, _("\
+Set autoloading of shared library symbols."), _("\
+Show autoloading of shared library symbols."), _("\
 If \"on\", symbols from all shared object libraries will be loaded\n\
 automatically when the inferior begins execution, when the dynamic linker\n\
 informs gdb that a new library has been loaded, or when attaching to the\n\
-inferior.  Otherwise, symbols must be loaded manually, using `sharedlibrary'.",
-		  &setlist),
-     &showlist);
+inferior.  Otherwise, symbols must be loaded manually, using `sharedlibrary'."),
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
 }
Index: cli/cli-cmds.c
===================================================================
RCS file: /cvs/src/src/gdb/cli/cli-cmds.c,v
retrieving revision 1.53
diff -p -u -r1.53 cli-cmds.c
--- cli/cli-cmds.c	15 Feb 2005 15:49:26 -0000	1.53
+++ cli/cli-cmds.c	18 Feb 2005 15:16:46 -0000
@@ -1121,12 +1121,12 @@ when gdb is started."), &cmdlist);
   add_com_alias ("q", "quit", class_support, 1);
   add_com_alias ("h", "help", class_support, 1);
 
-  c = add_set_cmd ("verbose", class_support, var_boolean, (char *) &info_verbose,
-		   "Set ",
-		   &setlist),
-    deprecated_add_show_from_set (c, &showlist);
-  set_cmd_sfunc (c, set_verbose);
-  set_verbose (NULL, 0, c);
+  add_setshow_boolean_cmd ("verbose", class_support, &info_verbose, _("\
+Set verbosity."), _("\
+Show verbosity."), NULL,
+			   set_verbose,
+			   NULL, /* FIXME: i18n: */
+			   &setlist, &showlist);
 
   add_prefix_cmd ("history", class_support, set_history,
 		  _("Generic command for setting command history parameters."),
@@ -1135,11 +1135,13 @@ when gdb is started."), &cmdlist);
 		  _("Generic command for showing command history parameters."),
 		  &showhistlist, "show history ", 0, &showlist);
 
-  deprecated_add_show_from_set
-    (add_set_cmd ("expansion", no_class, var_boolean, (char *) &history_expansion_p,
-		  "Set history expansion on command input.\n\
-Without an argument, history expansion is enabled.", &sethistlist),
-     &showhistlist);
+  add_setshow_boolean_cmd ("expansion", no_class, &history_expansion_p, _("\
+Set history expansion on command input."), _("\
+Show history expansion on command input."), _("\
+Without an argument, history expansion is enabled."),
+			   NULL,
+			   NULL, /* FIXME: i18n: */
+			   &sethistlist, &showhistlist);
 
   add_prefix_cmd ("info", class_info, info_command, _("\
 Generic command for showing things about the program being debugged."),

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]