From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 129856 invoked by alias); 11 Oct 2016 21:28:30 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 129828 invoked by uid 89); 11 Oct 2016 21:28:28 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.2 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS,SPF_SOFTFAIL autolearn=no version=3.3.2 spammy=ifs, H*r:112, daily, book X-HELO: simark.ca Received: from simark.ca (HELO simark.ca) (158.69.221.121) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 11 Oct 2016 21:28:26 +0000 Received: by simark.ca (Postfix, from userid 112) id 261891E131; Tue, 11 Oct 2016 17:28:25 -0400 (EDT) Received: from simark.ca (localhost [127.0.0.1]) by simark.ca (Postfix) with ESMTP id 13E651E124; Tue, 11 Oct 2016 17:28:24 -0400 (EDT) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Tue, 11 Oct 2016 21:28:00 -0000 From: Simon Marchi To: Eli Zaretskii Cc: palves@redhat.com, brobecker@adacore.com, markus.t.metzger@intel.com, gdb-patches@sourceware.org Subject: Re: [PATCH 1/3] Introduce gdb::unique_ptr In-Reply-To: <83twcibo91.fsf@gnu.org> References: <1476117992-5689-1-git-send-email-palves@redhat.com> <1476117992-5689-2-git-send-email-palves@redhat.com> <20161011121639.GE3813@adacore.com> <68fc02cb-59bc-012c-d1be-b5ed2076d6a5@redhat.com> <20161011144741.GF3813@adacore.com> <83insydifw.fsf@gnu.org> <83a8eadds7.fsf@gnu.org> <4d49eb8f-5a0c-1e7e-d082-1a224179184f@redhat.com> <831szmd977.fsf@gnu.org> <4aba16c0ae13533cd9e93f0f2823b042@simark.ca> <83twcibo91.fsf@gnu.org> Message-ID: <3fae204de19f0105e6dcda05014ad96b@simark.ca> X-Sender: simon.marchi@polymtl.ca User-Agent: Roundcube Webmail/1.2.0 X-IsSubscribed: yes X-SW-Source: 2016-10/txt/msg00281.txt.bz2 On 2016-10-11 16:54, Eli Zaretskii wrote: > Then why was there talk to use -std=gnu++11? For those compilers that support C++11, but default to C++03. If the feature is present and using it provides use with better error-checking, why not use it? > That's not "stick to C++03" in my book. Sticking to C++03 means not > writing any code that requires a later standard at all. That's your interpretation. I prefer to interpret it as compilable with a C++03 compiler, with no significant difference in the resulting behaviour. > Exactly like > we did when we required C90, but not C99: we had no code written for > C99 compilers, #ifdef'ed away for C90 compilers. Everything was C90. Maybe because there wasn't a need or reason to do so? In this case, there appears to be some value doing it. Do you question the fact that it brings value at all, or that that value is not worth the extra complexity? I am sure nobody wants to see the whole code base sprinkled with such #ifs. But here it's isolated in a file that we'll almost never touch again, and which will significantly improve the rest of the code base, with which we work with daily. >> The warning analogy was perhaps not clearly expressed but I think it >> was >> good. > > No, it wasn't: warnings don't affect code at all. This suggestion > clearly will. I made sure to point that out at the end of my paragraph, but anyway the analogy is not the important point here.