aboutsummaryrefslogtreecommitdiff
path: root/gdb/cris-tdep.c
diff options
context:
space:
mode:
authorAndrew Cagney <cagney@redhat.com>2002-03-18 02:26:32 +0000
committerAndrew Cagney <cagney@redhat.com>2002-03-18 02:26:32 +0000
commit1868c04ebae02e64e51631c2614703b4a294be6b (patch)
tree6e28234f7e1e80582ef5283f375dc9144bf256d5 /gdb/cris-tdep.c
parent4dae1ae7485e87401ae69bcc4f399c11a089b0d8 (diff)
downloadfsf-binutils-gdb-1868c04ebae02e64e51631c2614703b4a294be6b.zip
fsf-binutils-gdb-1868c04ebae02e64e51631c2614703b4a294be6b.tar.gz
fsf-binutils-gdb-1868c04ebae02e64e51631c2614703b4a294be6b.tar.bz2
* cli/cli-decode.c (cmd_type): New function.
* command.h (cmd_type): Declare. * infrun.c (set_schedlock_func): Call function cmd_type. * kod.c (kod_set_os): Call cmd_type. * cris-tdep.c (cris_version_update): Use function cmd_type. (cris_mode_update, cris_abi_update): Ditto.
Diffstat (limited to 'gdb/cris-tdep.c')
-rw-r--r--gdb/cris-tdep.c33
1 files changed, 30 insertions, 3 deletions
diff --git a/gdb/cris-tdep.c b/gdb/cris-tdep.c
index 4662eba..9a52611 100644
--- a/gdb/cris-tdep.c
+++ b/gdb/cris-tdep.c
@@ -3925,8 +3925,17 @@ cris_version_update (char *ignore_args, int from_tty,
{
struct gdbarch_info info;
+ /* NOTE: cagney/2002-03-17: The add_show_from_set() function clones
+ the set command passed as a parameter. The clone operation will
+ include (BUG?) any ``set'' command callback, if present.
+ Commands like ``info set'' call all the ``show'' command
+ callbacks. Unfortunatly, for ``show'' commands cloned from
+ ``set'', this includes callbacks belonging to ``set'' commands.
+ Making this worse, this only occures if add_show_from_set() is
+ called after add_cmd_sfunc() (BUG?). */
+
/* From here on, trust the user's CRIS version setting. */
- if (c->type == set_cmd)
+ if (cmd_type (c) == set_cmd)
{
usr_cmd_cris_version_valid = 1;
@@ -3943,8 +3952,17 @@ cris_mode_update (char *ignore_args, int from_tty,
{
struct gdbarch_info info;
+ /* NOTE: cagney/2002-03-17: The add_show_from_set() function clones
+ the set command passed as a parameter. The clone operation will
+ include (BUG?) any ``set'' command callback, if present.
+ Commands like ``info set'' call all the ``show'' command
+ callbacks. Unfortunatly, for ``show'' commands cloned from
+ ``set'', this includes callbacks belonging to ``set'' commands.
+ Making this worse, this only occures if add_show_from_set() is
+ called after add_cmd_sfunc() (BUG?). */
+
/* From here on, trust the user's CRIS mode setting. */
- if (c->type == set_cmd)
+ if (cmd_type (c) == set_cmd)
{
usr_cmd_cris_mode_valid = 1;
@@ -3961,8 +3979,17 @@ cris_abi_update (char *ignore_args, int from_tty,
{
struct gdbarch_info info;
+ /* NOTE: cagney/2002-03-17: The add_show_from_set() function clones
+ the set command passed as a parameter. The clone operation will
+ include (BUG?) any ``set'' command callback, if present.
+ Commands like ``info set'' call all the ``show'' command
+ callbacks. Unfortunatly, for ``show'' commands cloned from
+ ``set'', this includes callbacks belonging to ``set'' commands.
+ Making this worse, this only occures if add_show_from_set() is
+ called after add_cmd_sfunc() (BUG?). */
+
/* From here on, trust the user's CRIS ABI setting. */
- if (c->type == set_cmd)
+ if (cmd_type (c) == set_cmd)
{
usr_cmd_cris_abi_valid = 1;