[PATCH 1/3] Introduce gdb::unique_ptr

Joel Brobecker brobecker@adacore.com
Tue Oct 11 14:47:00 GMT 2016


> In the particular issue of an owning smart pointer, I think the
> shim as I'm proposing buys us some time, and unblocks a lot more
> struct cleanup elimination and simplification of the codebase.
> I'd still propose going forward with it immediately.

That would make sense to me.

> > Note that I wouldn't necessarily think in purely in terms of which
> > version of GCC supports it, but also consider whether want to support
> > building GDB with non-GCC compilers, particularly on the more exotic
> > systems out there, where it can be hard to build GDB. Do all these
> > compilers support C++11? Probably not.  
> 
> Looking at:
> 
>   https://sourceware.org/gdb/wiki/Systems
> 
> I think we're pretty much down to not-that-exotic hosts nowadays.
> At least, all hosts there seem to me like should have working
> gcc or clang ports.

Agreed. Mostly, I was thinking of seeing if we can avoid the requirement
to build a GCC first, if all you are interested in is actually building
GDB. But, if C++11 is a much cleaner language overall, and its runtime
provides some nice additions, I think it makes better sense technically
to align ourselves to it. We've already made a huge requirement jump;
let's just do it right all the way. That increment doesn't seem all
that significant compared to requiring a C++ compiler.

-- 
Joel



More information about the Gdb-patches mailing list