public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Alexandra Petlanova Hajkova <ahajkova@redhat.com>
To: Tom Tromey <tom@tromey.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCH] Remove error_stream
Date: Mon, 17 Apr 2023 12:55:16 +0200	[thread overview]
Message-ID: <CAJVr-EONW8kwfNuTk95SN2PFnYEEmrjDyRFbqnqAZoN=agee7w@mail.gmail.com> (raw)
In-Reply-To: <20230416184833.391586-1-tom@tromey.com>

[-- Attachment #1: Type: text/plain, Size: 950 bytes --]

On Sun, Apr 16, 2023 at 8:49 PM Tom Tromey <tom@tromey.com> wrote:

> error_stream is trivial and only used in a couple of spots in
> breakpoint.c.  This patch removes it in favor of just writing it out
> at the spots where it was used.
> ---
>  gdb/breakpoint.c | 4 ++--
>  gdb/utils.c      | 6 ------
>  gdb/utils.h      | 2 --
>  3 files changed, 2 insertions(+), 10 deletions(-)
>
> diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
> index 46287da5f87..baf49e4461f 100644
> --- a/gdb/breakpoint.c
> +++ b/gdb/breakpoint.c
> @@ -3137,7 +3137,7 @@ update_inserted_breakpoint_locations (void)
>    if (error_flag)
>      {
>        target_terminal::ours_for_output ();
> -      error_stream (tmp_error_stream);
> +      error (("%s"), tmp_error_stream.c_str ());
>
> I was considering using it in my "defer warnings when loading separate
debug file" but it wasn't suitable, it seems it doesn't have many use cases
indeed.

  reply	other threads:[~2023-04-17 10:55 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-16 18:48 Tom Tromey
2023-04-17 10:55 ` Alexandra Petlanova Hajkova [this message]
2023-05-02 15:15   ` Tom Tromey

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAJVr-EONW8kwfNuTk95SN2PFnYEEmrjDyRFbqnqAZoN=agee7w@mail.gmail.com' \
    --to=ahajkova@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=tom@tromey.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).