gdb_puts ("UFL ", file);
if (flags & (1 << 4))
gdb_puts ("INX ", file);
- fputc_filtered ('\n', file);
+ gdb_putc ('\n', file);
}
/* Print interesting information about the floating point processor
}
else if (c->catch_all)
fprintf_unfiltered (fp, " all");
- fputc_unfiltered ('\n', fp);
+ gdb_putc ('\n', fp);
}
/* Implement the "explains_signal" breakpoint_ops method for signal
delete_breakpoint (iter);
}
if (from_tty)
- putchar_filtered ('\n');
+ gdb_putc ('\n');
}
\f
/* Delete breakpoint in BS if they are `delete' breakpoints and
case C_CHAR:
break;
case C_WIDE_CHAR:
- fputc_filtered ('L', stream);
+ gdb_putc ('L', stream);
break;
case C_CHAR_16:
- fputc_filtered ('u', stream);
+ gdb_putc ('u', stream);
break;
case C_CHAR_32:
- fputc_filtered ('U', stream);
+ gdb_putc ('U', stream);
break;
}
- fputc_filtered ('\'', stream);
+ gdb_putc ('\'', stream);
emitchar (c, type, stream, '\'');
- fputc_filtered ('\'', stream);
+ gdb_putc ('\'', stream);
}
/* Print the character string STRING, printing at most LENGTH
cli_ui_out::field_separator ()
{
if (test_flags (unfiltered_output))
- fputc_unfiltered (' ', m_streams.back ());
+ gdb_putc (' ', m_streams.back ());
else
- fputc_filtered (' ', m_streams.back ());
+ gdb_putc (' ', m_streams.back ());
}
/* Constructor for cli_ui_out. */
compile_cplus_debug_output (T arg, Targs... Args)
{
compile_cplus_debug_output_1 (arg);
- fputc_unfiltered (' ', gdb_stdlog);
+ gdb_putc (' ', gdb_stdlog);
compile_cplus_debug_output (Args...);
}
{ \
gdb_puts (": ", gdb_stdlog); \
compile_cplus_debug_output (R); \
- fputc_unfiltered ('\n', gdb_stdlog); \
+ gdb_putc ('\n', gdb_stdlog); \
} \
#define GCC_METHOD0(R, N) \
fprintf_unfiltered (gdb_stdlog, "tailcall: initial:");
for (idx = 0; idx < length; idx++)
tailcall_dump (gdbarch, result->call_site[idx]);
- fputc_unfiltered ('\n', gdb_stdlog);
+ gdb_putc ('\n', gdb_stdlog);
}
return;
fprintf_unfiltered (gdb_stdlog, "tailcall: compare:");
for (idx = 0; idx < length; idx++)
tailcall_dump (gdbarch, chain[idx]);
- fputc_unfiltered ('\n', gdb_stdlog);
+ gdb_putc ('\n', gdb_stdlog);
}
/* Intersect callers. */
tailcall_dump (gdbarch,
(*resultp)->call_site[(*resultp)->length
- (*resultp)->callees + idx]);
- fputc_unfiltered ('\n', gdb_stdlog);
+ gdb_putc ('\n', gdb_stdlog);
}
if ((*resultp)->callers == 0 && (*resultp)->callees == 0)
case DW_OP_entry_value:
case DW_OP_GNU_entry_value:
data = safe_read_uleb128 (data, end, &ul);
- fputc_filtered ('\n', stream);
+ gdb_putc ('\n', stream);
disassemble_dwarf_expression (stream, arch, addr_size, offset_size,
start, data, data + ul, indent + 2,
all, per_cu, per_objfile);
continue;
if (*any_printed)
- putchar_filtered ('\n');
+ gdb_putc ('\n');
else
*any_printed = 1;
if (sym->print_name ())
except.what ());
}
- putchar_filtered ('\n');
+ gdb_putc ('\n');
}
}
}
if (s[i] == '\0')
gdb_puts ("\\000", stream);
else
- fputc_filtered (s[i], stream);
+ gdb_putc (s[i], stream);
}
}
if (string.get ()[i] == '\0')
gdb_puts ("\\000", stream);
else
- fputc_filtered (string.get ()[i], stream);
+ gdb_putc (string.get ()[i], stream);
}
}
result = STRING_REPR_OK;
pif (Large_frame);
pif (alloca_frame);
- putchar_filtered ('\n');
+ gdb_putc ('\n');
#define pin(FLD) printf_filtered ("\t"#FLD" = 0x%x\n", u->FLD);
printf_filtered (", <%s>", msym.minsym->linkage_name ());
}
- putchar_filtered ('\n');
+ gdb_putc ('\n');
}
if (printed == NULL)
{
const char *file_endianness
= bfd_big_endian (info.abfd) ? "big" : "little";
- fputc_unfiltered ('\n', gdb_stderr);
+ gdb_putc ('\n', gdb_stderr);
if (module_name)
warning (_("the MeP module '%s' is %s-endian, but the executable\n"
"%s is %s-endian."),
gdb_puts (m_prefix, m_raw);
if (m_quote)
{
- fputc_unfiltered (m_quote, m_raw);
+ gdb_putc (m_quote, m_raw);
m_raw->putstrn (buf, length_buf, m_quote);
- fputc_unfiltered (m_quote, m_raw);
- fputc_unfiltered ('\n', m_raw);
+ gdb_putc (m_quote, m_raw);
+ gdb_putc ('\n', m_raw);
}
else
{
m_raw->putstrn (buf, length_buf, 0);
- fputc_unfiltered ('\n', m_raw);
+ gdb_putc ('\n', m_raw);
}
gdb_flush (m_raw);
}
if (m_suppress_field_separator)
m_suppress_field_separator = false;
else
- fputc_unfiltered (',', m_streams.back ());
+ gdb_putc (',', m_streams.back ());
}
void
switch (type)
{
case ui_out_type_tuple:
- fputc_unfiltered ('{', stream);
+ gdb_putc ('{', stream);
break;
case ui_out_type_list:
- fputc_unfiltered ('[', stream);
+ gdb_putc ('[', stream);
break;
default:
switch (type)
{
case ui_out_type_tuple:
- fputc_unfiltered ('}', stream);
+ gdb_putc ('}', stream);
break;
case ui_out_type_list:
- fputc_unfiltered (']', stream);
+ gdb_putc (']', stream);
break;
default:
gdb_puts (" inval", file);
if (flags & (1 << 5))
gdb_puts (" unimp", file);
- fputc_filtered ('\n', file);
+ gdb_putc ('\n', file);
}
/* Print interesting information about the floating point processor
for (i = 1; i <= 7; i++)
if (fcs & (1 << (24 + i)))
fprintf_filtered (file, " %d", i);
- fputc_filtered ('\n', file);
+ gdb_putc ('\n', file);
gdb_puts ("cause :", file);
print_fpu_flags (file, (fcs >> 12) & 0x3f);
gdb_puts (" zero", file);
if ((fcs & (0xb << 21)) == 0)
gdb_puts (" no", file);
- fputc_filtered ('\n', file);
+ gdb_putc ('\n', file);
fprintf_filtered (file, "nan2008 : %s\n", fcs & (1 << 18) ? "yes" : "no");
fprintf_filtered (file, "abs2008 : %s\n", fcs & (1 << 19) ? "yes" : "no");
- fputc_filtered ('\n', file);
+ gdb_putc ('\n', file);
default_print_float_info (gdbarch, file, frame, args);
}
physname += len;
for (j = 0; j < i; ++j)
- fputc_filtered (physname[j], stream);
+ gdb_putc (physname[j], stream);
physname += i;
if (physname[0] != 0)
{
char c = (fromhex (p[0]) << 4) + fromhex (p[1]);
- fputc_unfiltered (c, outbuf);
+ gdb_putc (c, outbuf);
}
break;
}
{
gdb_byte c = buf[i];
if (isprint (c))
- fputc_unfiltered (c, &stb);
+ gdb_putc (c, &stb);
else
fprintf_unfiltered (&stb, "\\x%02x", (unsigned char) c);
}
else if (ch == '\0')
gdb_puts ("\\0", stream);
else if (ch >= 32 && ch <= 127 && isprint (ch))
- fputc_filtered (ch, stream);
+ gdb_putc (ch, stream);
else if (ch <= 255)
fprintf_filtered (stream, "\\x%02x", ch);
else
const int stop_1 = 15;
const int stop_2 = 17;
for (int i = 0; i < stop_1 - len; ++i)
- fputc_filtered (' ', file);
+ gdb_putc (' ', file);
fprintf_filtered (file, "0x%04x", ccw);
for (int i = 0; i < stop_2 - len; ++i)
- fputc_filtered (' ', file);
+ gdb_putc (' ', file);
for (int b = 15; b >= 0; --b)
{
if (ccw & (0x1u << b))
{
if (ccw_bits[b] == 0)
- fputc_filtered ('1', file);
+ gdb_putc ('1', file);
else
- fputc_filtered (ccw_bits[b], file);
+ gdb_putc (ccw_bits[b], file);
}
else
- fputc_filtered (tolower (ccw_bits[b]), file);
+ gdb_putc (tolower (ccw_bits[b]), file);
}
- fputc_filtered ('\n', file);
+ gdb_putc ('\n', file);
}
static void
}
if (serial_logbase != logbase_ascii)
- fputc_unfiltered (' ', stream);
+ gdb_putc (' ', stream);
switch (ch)
{
}
}
- fputc_unfiltered ('\n', gdb_stdlog);
+ gdb_putc ('\n', gdb_stdlog);
}
/* Check implementations of to_xfer_partial update *XFERED_LEN
int
ui_file::putc (int c)
{
- return fputc_unfiltered (c, this);
+ char copy = (char) c;
+ write (©, 1);
+ return c;
}
void
/* Output the part before pmatch with current style. */
while (pmatch.rm_so > 0)
{
- fputc_filtered (*str, stream);
+ gdb_putc (*str, stream);
pmatch.rm_so--;
str++;
}
stream->emit_style_escape (highlight_style.style ());
while (n_highlight > 0)
{
- fputc_filtered (*str, stream);
+ gdb_putc (*str, stream);
n_highlight--;
str++;
}
May return nonlocally. */
int
-putchar_filtered (int c)
+gdb_putc (int c)
{
- return fputc_filtered (c, gdb_stdout);
+ return gdb_stdout->putc (c);
}
int
-fputc_unfiltered (int c, struct ui_file *stream)
+gdb_putc (int c, struct ui_file *stream)
{
- char buf[2];
-
- buf[0] = c;
- buf[1] = 0;
- gdb_puts (buf, stream);
- return c;
-}
-
-int
-fputc_filtered (int c, struct ui_file *stream)
-{
- char buf[2];
-
- buf[0] = c;
- buf[1] = 0;
- gdb_puts (buf, stream);
- return c;
+ return stream->putc (c);
}
void
extern void gdb_puts (const char *, struct ui_file *);
-extern int fputc_filtered (int c, struct ui_file *);
+extern int gdb_putc (int c, struct ui_file *);
-extern int fputc_unfiltered (int c, struct ui_file *);
-
-extern int putchar_filtered (int c);
+extern int gdb_putc (int c);
extern void gdb_puts (const char *);
b = '0';
if (zero_pad || seen_a_one || b == '1')
- fputc_filtered (b, stream);
+ gdb_putc (b, stream);
if (b == '1')
seen_a_one = true;
}
b = '0';
if (zero_pad || seen_a_one || b == '1')
- fputc_filtered (b, stream);
+ gdb_putc (b, stream);
if (b == '1')
seen_a_one = true;
}
/* When not zero-padding, ensure that something is printed when the
input is 0. */
if (!zero_pad && !seen_a_one)
- fputc_filtered ('0', stream);
+ gdb_putc ('0', stream);
}
/* A helper for print_octal_chars that emits a single octal digit,