From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 74990 invoked by alias); 7 Mar 2019 18:09:34 -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 74981 invoked by uid 89); 7 Mar 2019 18:09:34 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.1 spammy=HContent-Transfer-Encoding:8bit X-HELO: smtp.polymtl.ca Received: from smtp.polymtl.ca (HELO smtp.polymtl.ca) (132.207.4.11) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 07 Mar 2019 18:09:33 +0000 Received: from simark.ca (simark.ca [158.69.221.121]) (authenticated bits=0) by smtp.polymtl.ca (8.14.7/8.14.7) with ESMTP id x27I9QOq004925 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 7 Mar 2019 13:09:31 -0500 Received: by simark.ca (Postfix, from userid 112) id A39521E658; Thu, 7 Mar 2019 13:09:26 -0500 (EST) Received: from simark.ca (localhost [127.0.0.1]) by simark.ca (Postfix) with ESMTP id C74011E4A5; Thu, 7 Mar 2019 13:09:25 -0500 (EST) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Date: Thu, 07 Mar 2019 18:09:00 -0000 From: Simon Marchi To: Pedro Alves Cc: Eli Zaretskii , gdb-patches@sourceware.org Subject: Re: MinGW build failure for GDB 8.2.90 with source-highlight In-Reply-To: <10c9e85f-d216-ef5c-c8ca-636331d0d1ba@redhat.com> References: <83r2bibvlv.fsf@gnu.org> <10c9e85f-d216-ef5c-c8ca-636331d0d1ba@redhat.com> Message-ID: <353a11fc68f77c293d7b706586b06724@polymtl.ca> X-Sender: simon.marchi@polymtl.ca User-Agent: Roundcube Webmail/1.3.6 X-IsSubscribed: yes X-SW-Source: 2019-03/txt/msg00162.txt.bz2 On 2019-03-07 12:11, Pedro Alves wrote: > On 03/07/2019 04:59 PM, Simon Marchi wrote: > >> I don't recall what's the long term solution for this.  We could use >> gnulib's namespace support [2], but the disadvantage is that we would >> need to use gnulib::some_function (assuming we name the namespace >> "gnulib") instead of just some_function to use the "fixed" version.  >> If we use some_function directly, it will use the buggy version on >> those systems where it is buggy. > > Wrap all of gdb in a namespace. Recall that this was what led to C++ > wildmatching support. I don't understand how this will help. If you have #define open rpl_open namespace gdb { struct target_ops { void open(); } } The macro will still wrongfully replace open. Simon