From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [63.128.21.124]) by sourceware.org (Postfix) with ESMTP id 0E2F33857C64 for ; Fri, 13 Nov 2020 23:29:24 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 0E2F33857C64 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-588-rG1R8WzKOrmhh4gp3mWtYA-1; Fri, 13 Nov 2020 18:29:20 -0500 X-MC-Unique: rG1R8WzKOrmhh4gp3mWtYA-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 12ED457001; Fri, 13 Nov 2020 23:29:19 +0000 (UTC) Received: from localhost.localdomain (ovpn-112-176.phx2.redhat.com [10.3.112.176]) by smtp.corp.redhat.com (Postfix) with ESMTP id CBAD15C225; Fri, 13 Nov 2020 23:29:18 +0000 (UTC) Subject: Re: [PATCH v2] c: Silently ignore pragma region [PR85487] To: Austin Morton Cc: GCC Patches References: <98207018-7512-c842-94d9-cc3125b0b2c8@redhat.com> From: Jeff Law Message-ID: <0f1fa4df-779a-ddef-f1dc-cb87dfd47081@redhat.com> Date: Fri, 13 Nov 2020 16:29:18 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.3.1 MIME-Version: 1.0 In-Reply-To: X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Content-Language: en-US X-Spam-Status: No, score=-5.6 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, NICE_REPLY_A, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H5, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 13 Nov 2020 23:29:26 -0000 On 11/13/20 7:57 AM, Austin Morton wrote: > On the contrary, as a user of GCC I would much prefer a consistent > behavior for #pragma region based purely on GCC version. You can get consistent behavior with a command line argument and it's much more useful over time as the world changes. > > IE, so you can tell people: > "just update to GCC X.Y and those warnings will go away" > rather than: > "update to GCC X.Y and pass some new flags - but make sure > not to pass them to old GCC versions, since that will generate > a new warning" I'm aware of those benefits.  But I would still claim that embedding knowledge of other toolchain's pragmas into GCC  itself is just plain wrong from a design standpoint.   A flag to allow specifying pragmas to ignore would be much more useful and gets you the same level of consistency with a much higher degree of control and future proofing. Being able to specify them in a file would be even better (IMHO) I'm not going to ACK this patch.  However, I won't object if someone else wants to ACK it. Jeff