From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 79251 invoked by alias); 30 Nov 2016 16:38:44 -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 79184 invoked by uid 89); 30 Nov 2016 16:38:43 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-4.8 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=exclude X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 30 Nov 2016 16:38:33 +0000 Received: from int-mx13.intmail.prod.int.phx2.redhat.com (int-mx13.intmail.prod.int.phx2.redhat.com [10.5.11.26]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 74589624AC; Wed, 30 Nov 2016 16:38:32 +0000 (UTC) Received: from [127.0.0.1] (ovpn03.gateway.prod.ext.phx2.redhat.com [10.5.9.3]) by int-mx13.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id uAUGcVaw028400; Wed, 30 Nov 2016 11:38:31 -0500 Subject: Re: [PATCH 1/3] Fix mismatched struct vs class tags. To: John Baldwin References: <20161123200652.89209-1-jhb@FreeBSD.org> <1573845.CKxfuZpZBq@ralph.baldwin.cx> <31fa3dbd-e1d1-1fd2-7774-8bc82fd8b37d@redhat.com> <1853167.ixQKmG4D0P@ralph.baldwin.cx> Cc: Simon Marchi , gdb-patches@sourceware.org From: Pedro Alves Message-ID: Date: Wed, 30 Nov 2016 16:38:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 MIME-Version: 1.0 In-Reply-To: <1853167.ixQKmG4D0P@ralph.baldwin.cx> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-SW-Source: 2016-11/txt/msg01000.txt.bz2 On 11/30/2016 04:23 PM, John Baldwin wrote: > Oh certainly. My only point is that to get a -Werror clang build working > I'd need a way to exclude -Wunused-function from WARNFLAGS for clang. That's > the part I wasn't sure how to handle. I still need to see about adding > -Wno-foo for some other clang-only warnings to trim other bits of noise from > clang's build. Yeah, I think we'd need to add some "is this clang?" check somehow. > One other clangism is that clang warns about compiling a .c file in C++. > It wants an explicit '-x c++' to force the language mode. However, simply > adding this to CXX_FLAGS doesn't work as it is included in both compiling > and linking (and for the link it causes clang to try to parse all the object > files as C++ source leading to bizarre errors). Do you get the same when building GCC? If not, how is this handled over there? Does clang have a way to suppress that warning? Some -Wno-stop-complaining-about-c-file-in-cxx switch, perhaps? > I assume a massive .c -> .cc > (or .cxx, etc.) rename is not in the roadmap (it would presumably be very > disruptive to pending patchsets)? We briefly last discussed that here: https://sourceware.org/ml/gdb-patches/2016-09/msg00309.html The quick consensus was "no". Thanks, Pedro Alves