X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=gdb%2Fguile%2Fguile.c;h=2b82f82820fe3612451214f1c1b5f6c625a55d56;hb=0743fc83c03da263953dfc393a66744a08770365;hp=506836157ee35ee2af1fb873af580646cf44924d;hpb=b811d2c2920ddcb1adcd438da38e90912b31f45f;p=deliverable%2Fbinutils-gdb.git diff --git a/gdb/guile/guile.c b/gdb/guile/guile.c index 506836157e..2b82f82820 100644 --- a/gdb/guile/guile.c +++ b/gdb/guile/guile.c @@ -396,33 +396,6 @@ static struct cmd_list_element *set_guile_list; static struct cmd_list_element *show_guile_list; static struct cmd_list_element *info_guile_list; -/* Function for use by 'set guile' prefix command. */ - -static void -set_guile_command (const char *args, int from_tty) -{ - help_list (set_guile_list, "set guile ", all_commands, gdb_stdout); -} - -/* Function for use by 'show guile' prefix command. */ - -static void -show_guile_command (const char *args, int from_tty) -{ - cmd_show_list (show_guile_list, from_tty, ""); -} - -/* The "info scheme" command is defined as a prefix, with - allow_unknown 0. Therefore, its own definition is called only for - "info scheme" with no args. */ - -static void -info_guile_command (const char *args, int from_tty) -{ - printf_unfiltered (_("\"info guile\" must be followed" - " by the name of an info command.\n")); - help_list (info_guile_list, "info guile ", all_commands, gdb_stdout); -} /* Initialization. */ @@ -761,22 +734,22 @@ This command is only a placeholder.") ); add_com_alias ("gu", "guile", class_obscure, 1); - add_prefix_cmd ("guile", class_obscure, set_guile_command, - _("Prefix command for Guile preference settings."), - &set_guile_list, "set guile ", 0, - &setlist); + add_basic_prefix_cmd ("guile", class_obscure, + _("Prefix command for Guile preference settings."), + &set_guile_list, "set guile ", 0, + &setlist); add_alias_cmd ("gu", "guile", class_obscure, 1, &setlist); - add_prefix_cmd ("guile", class_obscure, show_guile_command, - _("Prefix command for Guile preference settings."), - &show_guile_list, "show guile ", 0, - &showlist); + add_show_prefix_cmd ("guile", class_obscure, + _("Prefix command for Guile preference settings."), + &show_guile_list, "show guile ", 0, + &showlist); add_alias_cmd ("gu", "guile", class_obscure, 1, &showlist); - add_prefix_cmd ("guile", class_obscure, info_guile_command, - _("Prefix command for Guile info displays."), - &info_guile_list, "info guile ", 0, - &infolist); + add_basic_prefix_cmd ("guile", class_obscure, + _("Prefix command for Guile info displays."), + &info_guile_list, "info guile ", 0, + &infolist); add_info_alias ("gu", "guile", 1); /* The name "print-stack" is carried over from Python. @@ -792,8 +765,9 @@ message == an error message without a stack will be printed."), &set_guile_list, &show_guile_list); } +void _initialize_guile (); void -_initialize_guile (void) +_initialize_guile () { install_gdb_commands ();