aboutsummaryrefslogtreecommitdiff
path: root/gdb/cli/cli-style.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2022-01-02 11:46:15 -0700
committerTom Tromey <tom@tromey.com>2022-03-29 12:46:24 -0600
commit6cb06a8cdaaf30f5d879f24d37100cf1d25c6a3a (patch)
tree641a6a86240919fe4ba9219fbbbe15bc6331c22d /gdb/cli/cli-style.c
parenta11ac3b3e8ff6769badcf0041894f6c5acc1b94f (diff)
downloadgdb-6cb06a8cdaaf30f5d879f24d37100cf1d25c6a3a.zip
gdb-6cb06a8cdaaf30f5d879f24d37100cf1d25c6a3a.tar.gz
gdb-6cb06a8cdaaf30f5d879f24d37100cf1d25c6a3a.tar.bz2
Unify gdb printf functions
Now that filtered and unfiltered output can be treated identically, we can unify the printf family of functions. This is done under the name "gdb_printf". Most of this patch was written by script.
Diffstat (limited to 'gdb/cli/cli-style.c')
-rw-r--r--gdb/cli/cli-style.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/gdb/cli/cli-style.c b/gdb/cli/cli-style.c
index bdf7a3d..3fd85f4 100644
--- a/gdb/cli/cli-style.c
+++ b/gdb/cli/cli-style.c
@@ -189,7 +189,7 @@ do_show (const char *what, struct ui_file *file,
cli_style_option *cso = (cli_style_option *) cmd->context ();
gdb_puts (_("The "), file);
fprintf_styled (file, cso->style (), _("\"%s\" style"), cso->name ());
- fprintf_filtered (file, _(" %s is: %s\n"), what, value);
+ gdb_printf (file, _(" %s is: %s\n"), what, value);
}
/* See cli-style.h. */
@@ -299,9 +299,9 @@ show_style_enabled (struct ui_file *file, int from_tty,
struct cmd_list_element *c, const char *value)
{
if (cli_styling)
- fprintf_filtered (file, _("CLI output styling is enabled.\n"));
+ gdb_printf (file, _("CLI output styling is enabled.\n"));
else
- fprintf_filtered (file, _("CLI output styling is disabled.\n"));
+ gdb_printf (file, _("CLI output styling is disabled.\n"));
}
static void
@@ -309,9 +309,9 @@ show_style_sources (struct ui_file *file, int from_tty,
struct cmd_list_element *c, const char *value)
{
if (source_styling)
- fprintf_filtered (file, _("Source code styling is enabled.\n"));
+ gdb_printf (file, _("Source code styling is enabled.\n"));
else
- fprintf_filtered (file, _("Source code styling is disabled.\n"));
+ gdb_printf (file, _("Source code styling is disabled.\n"));
}
/* Implement 'show style disassembler'. */
@@ -321,9 +321,9 @@ show_style_disassembler (struct ui_file *file, int from_tty,
struct cmd_list_element *c, const char *value)
{
if (disassembler_styling)
- fprintf_filtered (file, _("Disassembler output styling is enabled.\n"));
+ gdb_printf (file, _("Disassembler output styling is enabled.\n"));
else
- fprintf_filtered (file, _("Disassembler output styling is disabled.\n"));
+ gdb_printf (file, _("Disassembler output styling is disabled.\n"));
}
void _initialize_cli_style ();