From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2309 invoked by alias); 23 Feb 2018 16:54:52 -0000 Mailing-List: contact elfutils-devel-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Post: List-Help: List-Subscribe: Sender: elfutils-devel-owner@sourceware.org Received: (qmail 2291 invoked by uid 89); 23 Feb 2018 16:54:51 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Checked: by ClamAV 0.99.2 on sourceware.org X-Virus-Found: No X-Spam-SWARE-Status: No, score=-24.8 required=5.0 tests=AWL,BAYES_00,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_NONE,T_RP_MATCHES_RCVD autolearn=ham version=3.3.2 spammy= X-Spam-Status: No, score=-24.8 required=5.0 tests=AWL,BAYES_00,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_NONE,T_RP_MATCHES_RCVD autolearn=ham version=3.3.2 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on sourceware.org X-Spam-Level: X-HELO: mail.rt-rk.com Received: from mx2.rt-rk.com (HELO mail.rt-rk.com) (89.216.37.149) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 23 Feb 2018 16:54:49 +0000 Received: from localhost (localhost [127.0.0.1]) by mail.rt-rk.com (Postfix) with ESMTP id 5BF9E1A2261; Fri, 23 Feb 2018 17:54:47 +0100 (CET) X-Virus-Scanned: amavisd-new at rt-rk.com Received: from [10.10.13.75] (djole.domain.local [10.10.13.75]) by mail.rt-rk.com (Postfix) with ESMTPSA id 44C201A221E; Fri, 23 Feb 2018 17:54:47 +0100 (CET) Subject: Re: [PATCH, dwarflint] Explicitly qualify specializations of elfutils::to_string From: Djordje Todorovic To: elfutils-devel@sourceware.org References: <20180223145402.12470-1-dmalcolm@redhat.com> <5c357b6d-c141-e990-52ef-c77198a3bbfb@rt-rk.com> Cc: David Malcolm Message-ID: <1d03eb08-73a2-6b3e-b7fa-641e678a829e@rt-rk.com> Date: Fri, 23 Feb 2018 16:54:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: <5c357b6d-c141-e990-52ef-c77198a3bbfb@rt-rk.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes X-SW-Source: 2018-q1/txt/msg00052.txt.bz2 ccing David On 23.02.2018. 17:47, Djordje Todorovic wrote: > Hi David, >=20 > This looks good to me, but Mark or someone else must approve. >=20 > Thanks, > Djordje >=20 > On 23.02.2018. 15:54, David Malcolm wrote: >> I attempted to build the "dwarflint" branch with gcc 7.3.1 , but ran >> into various problems of the form: >> >> c++/known.cc:220:1: error: explicit specialization of =E2=80=98template<= class type> std::__cxx11::string elfutils::to_string(const type&)=E2=80=99 = outside its namespace must use a nested-name-specifier [-fpermissive] >> to_string (const dwarf::dwarf_enum &value) >> ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ >> >> The fix appears to be trivial. >> >> libdw/ChangeLog: >> * c++/edit-values.cc (to_string): >> Explicitly qualify with "elfutils::". >> * c++/known.cc (to_string): Likewise. >> (to_string): Likewise. >> * c++/output-values.cc (to_string): >> Likewise. >> * c++/values.cc (to_string): Likewise. >> (to_string): Likewise. >> (to_string): Likewise. >> (to_string): Likewise. >> >> Signed-off-by: David Malcolm >> --- >> libdw/c++/edit-values.cc | 2 +- >> libdw/c++/known.cc | 4 ++-- >> libdw/c++/output-values.cc | 2 +- >> libdw/c++/values.cc | 8 ++++---- >> 4 files changed, 8 insertions(+), 8 deletions(-) >> >> diff --git a/libdw/c++/edit-values.cc b/libdw/c++/edit-values.cc >> index aefb5fd1..ca83a967 100644 >> --- a/libdw/c++/edit-values.cc >> +++ b/libdw/c++/edit-values.cc >> @@ -41,7 +41,7 @@ template class dwarf_data::value; >>=20=20 >> template<> >> std::string >> -to_string (const dwarf_edit::attribute &attr) >> +elfutils::to_string (const dwarf_edit::attribute= &attr) >> { >> return attribute_string (attr); >> } >> diff --git a/libdw/c++/known.cc b/libdw/c++/known.cc >> index bd84f52c..cb5fe693 100644 >> --- a/libdw/c++/known.cc >> +++ b/libdw/c++/known.cc >> @@ -217,14 +217,14 @@ enum_string (const value_type &value) >>=20=20 >> template<> >> string >> -to_string (const dwarf::dwarf_enum &value) >> +elfutils::to_string (const dwarf::dwarf_enum &value) >> { >> return enum_string (value); >> } >>=20=20 >> template<> >> string >> -to_string (const dwarf_data::dwarf_enum &value) >> +elfutils::to_string (const dwarf_data::dwarf_en= um &value) >> { >> return enum_string (value); >> } >> diff --git a/libdw/c++/output-values.cc b/libdw/c++/output-values.cc >> index 199c72bd..60abc0b5 100644 >> --- a/libdw/c++/output-values.cc >> +++ b/libdw/c++/output-values.cc >> @@ -46,7 +46,7 @@ template class dwarf_output::copier; >>=20=20 >> template<> >> std::string >> -to_string (const dwarf_output::attribute &attr) >> +elfutils::to_string (const dwarf_output::attri= bute &attr) >> { >> return attribute_string (attr); >> } >> diff --git a/libdw/c++/values.cc b/libdw/c++/values.cc >> index 335074fb..c70d793f 100644 >> --- a/libdw/c++/values.cc >> +++ b/libdw/c++/values.cc >> @@ -227,28 +227,28 @@ value_string (const value_type &value) >>=20=20 >> template<> >> string >> -to_string (const dwarf::attribute &attr) >> +elfutils::to_string (const dwarf::attribute &attr) >> { >> return attribute_string (attr); >> } >>=20=20 >> template<> >> string >> -to_string (const dwarf::attr_value &value) >> +elfutils::to_string (const dwarf::attr_value &value) >> { >> return value_string (value); >> } >>=20=20 >> template<> >> string >> -to_string (const dwarf_edit::attr_value &value) >> +elfutils::to_string (const dwarf_edit::attr_val= ue &value) >> { >> return value_string (value); >> } >>=20=20 >> template<> >> string >> -to_string (const dwarf_output::attr_value &va= lue) >> +elfutils::to_string (const dwarf_output::attr= _value &value) >> { >> return value_string (value); >> } >>