This is the mail archive of the mailing list for the GDB project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH 1/3] Introduce gdb::unique_ptr

> Cc:,,
> From: Pedro Alves <>
> Date: Tue, 11 Oct 2016 18:41:01 +0100
> On 10/11/2016 05:57 PM, Eli Zaretskii wrote:
> >> That's a misunderstanding.  Full C++11 support is available
> >> in gcc 4.8 already.
> > 
> > Yes, I know.  I'm just envisioning that once we require to build GCC,
> > we will soon require a new enough version of it.  Like Joel says:
> That still sounds like a misunderstanding, because we're not
> requiring that you build GCC.

Maybe it is indeed a misunderstanding, but then perhaps you could
re-read what you and Joel were saying, to see how such a
misunderstanding could happen, and avoid saying things in the future
that could be misinterpreted.

> We're talking about requiring C++11 support.  There's a difference.
> If you don't have a compiler that supports C++11, _then_ you'd have
> to build one.

As long as we stay with C++11, I have no problem (although it does
look like a huge jump, which we perhaps should have taken more slowly,
and stay with C++03 for now).  My problem begins where we will in a
few months jump so easily to C++14 and whatever else is after that.  I
see no reason not to fear this, do you?  Where are the rules and
decisions that we won't?

> That is, we're mainly talking about the trade off between getting
> access to C++11 and how that would improve the codebase and
> maintainability vs convenience of getting a new gdb built on an
> older system with an old system compiler.

Please don't forget that you look at these problems from the POV of
someone who always have the newest tools available.  I'm trying to
keep these decisions in their proper perspective by taking a POV of
someone whose tools are one or 2 major GCC releases older.

> > I see where it's going, and I don't like it.  We will make it hard on
> > users to build GDB.  Just 7 months ago all you needed was a C90
> > compiler, and look where we are now.
> There's no sekrit conspiracy here.

I didn't think there were a conspiracy.  But that doesn't help, does
it?  Such slippery slopes are known human tendency, the only way to
avoid that is not to step on the slope in the first place.

> > If we stay with 4.8 for long enough, I have no problem.  But we must
> > record this decision somewhere and stick to it, because otherwise it
> > will be one more domino to fall, and soon enough.
> Yes, of course if we move forward with a requirement change we'll
> document it.

I think we need to document that before we more forward.  Otherwise we
won't know whether we are moving forward or not, and won't know to
stop and think a bit before we do.

> It'll naturally end up reevaluated at some point, maybe years from
> now.  The jump from C++03 -> C++11 is _huge_.  C++11 -> C++14 not
> that much.

Then maybe we shouldn't make that huge jump, not just yet.  It was
never discussed seriously, AFAIK.

> >> I don't expect anyone to _have_ to build any mingw compiler to be able
> >> to build gdb for mingw.  
> > 
> > If you suddenly require 6.x or 7.x, they will have no choice.
> Well, that's (an unintended, no doubt) strawman, because no one is
> suggesting that.

That's not how I read your messages.  Apologies for my
misunderstanding, but I can show you how your words actually made that
sound as if you were.

> I'll make an analogy.  Think of it as if GCC 6.x enabled some
> useful warning flag by default that used to be disabled by default.

I don't think it's a good analogy.  You are not talking about warning
switches, are you?

> First, it's not true that these C++ changes have not been planned.
> They've been part of the plan ever since the very beginning.  See
> here, step 5 of the original version of the plan I originally
> circulated in 2014:
> Current version is here:
> Note the not-done-yet bullet points in step 8 (step 5 in rev 1).
> That's exactly what's going on right now.

Where does it say that we should require C++11?  Or any specific
version of the C++ standard, for that matter?  AFAIR, this was never

> > But I don't want to argue about C++, that was just an example of a
> > slippery slope similar to what I fear will happen once we require a
> > new enough GCC to be able to compile GDB.  I think that would be a bad
> > mistake.
> Again, no one's proposed that.  Heck, until today I was under the
> impression that gcc 4.8 was too new and had assumed proposing to require
> that for C++11 would be out of question.  But I'm very happy to
> learn that I've been mistaken!

I'd still be happier if you were not mistaken.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]