Remove vfprintf_styled_no_gdbfmt

This removes vfprintf_styled_no_gdbfmt, inlining it at the sole point
of call.
This commit is contained in:
Tom Tromey
2022-01-01 13:35:13 -07:00
parent c8d74a7b4b
commit 0e37c0638c
3 changed files with 8 additions and 28 deletions

View File

@@ -230,11 +230,14 @@ cli_ui_out::do_message (const ui_file_style &style,
if (m_suppress_output)
return;
/* Use the "no_gdbfmt" variant here to avoid recursion.
vfprintf_styled calls into cli_ui_out::message to handle the
gdb-specific printf formats. */
vfprintf_styled_no_gdbfmt (m_streams.back (), style,
!test_flags (unfiltered_output), format, args);
std::string str = string_vprintf (format, args);
if (!str.empty ())
{
if (test_flags (unfiltered_output))
fputs_styled_unfiltered (str.c_str (), style, m_streams.back ());
else
fputs_styled (str.c_str (), style, m_streams.back ());
}
}
void