public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Enze Li <enze.li@hotmail.com>
To: Simon Marchi <simark@simark.ca>, Manoj Gupta <manojgupta@google.com>
Cc: Christopher Di Bella <cjdb@google.com>, gdb-patches@sourceware.org
Subject: Re: [PATCH] [PATCH] [gdb] adds `<iterator>` to list of includes
Date: Sat, 16 Jul 2022 20:38:46 +0800	[thread overview]
Message-ID: <OS3P286MB21521C034608C9B43B270588F08A9@OS3P286MB2152.JPNP286.PROD.OUTLOOK.COM> (raw)
In-Reply-To: <9d0e7369-7ead-7ad7-c65c-604fe4ea0a57@simark.ca>

On Sun, 2022-07-10 at 14:52 -0400, Simon Marchi wrote:
> On 2022-07-09 04:54, Enze Li via Gdb-patches wrote:
> > Hi Manoj,
> > 
> > On Fri, 2022-07-08 at 22:57 -0700, Manoj Gupta wrote:
> > > I work on ChromeOS and can provide answers to this.
> > > 
> > > <vector> does not include provide std::back_inserter as per C++
> > > spec.
> > > It is provided by <iterator> [1].
> > > The fact that it worked so far is just an accident that libc++
> > > and
> > > libstdc++ were including this
> > > header with <vector>.
> > > With libc++, it is no longer true. See commit "[libc++] Removes
> > > unneeded <iterator> includes." in libc++ [2].
> > > It is therefore not surprising that gdb fails to build. 
> > 
> > Thank you for the detailed explanation.  It seems that we need to
> > manually compile and install the libc++ from upstream before we can
> > reproduce this issue.
> 
> This is trivial enough that it's not really necessary to reproduce to
> get convinced that such a change would be good.  The file uses
> back_inserter -> C++ says that back_inserter is provided by
> <iterator>
> -> make the file include <iterator>.  This has no real change of
> breaking anything.

Indeed, reproduction is not necessary.  I was just curious about
building gdb with libc++.  I hope my interruptions didn't interfere
with the progress of reviewing the patch.

Best Regards,
Enze

> 
> Simon


  reply	other threads:[~2022-07-16 12:38 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-28  1:04 Christopher Di Bella
2022-07-01 13:45 ` Enze Li
2022-07-01 21:50   ` Christopher Di Bella
2022-07-09  4:30     ` Enze Li
2022-07-09  5:57       ` Manoj Gupta
2022-07-09  8:54         ` Enze Li
2022-07-10 18:52           ` Simon Marchi
2022-07-16 12:38             ` Enze Li [this message]
2022-07-09  9:10 ` Andrew Burgess

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=OS3P286MB21521C034608C9B43B270588F08A9@OS3P286MB2152.JPNP286.PROD.OUTLOOK.COM \
    --to=enze.li@hotmail.com \
    --cc=cjdb@google.com \
    --cc=gdb-patches@sourceware.org \
    --cc=manojgupta@google.com \
    --cc=simark@simark.ca \
    /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).