This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: C++11 (abridged version)
- From: Kevin Buettner <kevin at buettner dot to>
- To: gdb-patches at sourceware dot org
- Date: Wed, 26 Oct 2016 17:04:08 -0700
- Subject: Re: C++11 (abridged version)
- Authentication-results: sourceware.org; auth=none
- References: <4300d24a-8711-c5de-79ce-7c530162288c@redhat.com>
On Thu, 20 Oct 2016 18:07:58 +0100
Pedro Alves <palves@redhat.com> wrote:
> My opinion on #3 (should we require C++11 now), is yes. C++11 is a
> great step up from C++03, and being able to use it fully would result
> in a more efficiency gdb, and would also allow simplifying things that
> require ugly workarounds in C++03. I.e., if you hate C++ and you think
> it's messy, it may actually be that what you hate is C++03, and that you'd
> actually like C++11 if you give it a chance. E.g., rvalue references, efficient
> move-aware containers (also allowing us to make containers "own" the containing
> objects, resulting in even simpler code), template aliases, variadic templates,
> etc. etc. C++11 would avoid having to consider reimplementing basic utilities
> like e.g., a type-safe hash table. C++11 is also a _simpler_ language in a way,
> as some ugly warts have been ironed out in the language (e.g., std::string
> and contiguous buffer guarantees).
While I claim no deep understanding of C++ (any version), I find this
point compelling. Therefore, I'm in favor of requiring C++11 for
building GDB.
Kevin