From patchwork Wed Jul 23 10:45:32 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Wakely X-Patchwork-Id: 372864 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 6F636140140 for ; Wed, 23 Jul 2014 20:45:54 +1000 (EST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:date :from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; q=dns; s=default; b=r21061BdxlVptkyHU oblqMOkKUvRxq5d+Voz9SrOForMOSUwyNz3HkbOZXTuOWwYXsOiNd8re1uyrBXoB thqVkRDOeseSxu8/mVJeUZciU/ro8AV8dfpn4aEYFPPJ8jLJMkh8U0W5TaKuuEXb z0B5q4s8Dv2ftlQk9z4msAdRXY= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:date :from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=default; bh=fm4loxDGwAWrfFu32yLfGzE /f8g=; b=ttUnuPtkmhZbFgIZfOD+lCcV6FNBfVq399vVwdAiGvTlnj+9d5S9i/V EhYAVePqSKvgMdPAWPuIaF9LkU+r8VHy560jY7WJIu9L5Rbc+4fGxKcZpTqVGNSK ZxVyubx2I0Xi03jl5wlABIYt/8Y+73ihA0TnFSrkEho/P+oWfvXs= Received: (qmail 7335 invoked by alias); 23 Jul 2014 10:45:37 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 7313 invoked by uid 89); 23 Jul 2014 10:45:36 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.0 required=5.0 tests=AWL, BAYES_00, RP_MATCHES_RCVD, SPF_HELO_PASS, SPF_PASS autolearn=ham version=3.3.2 X-Spam-User: qpsmtpd, 2 recipients 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 (AES256-GCM-SHA384 encrypted) ESMTPS; Wed, 23 Jul 2014 10:45:35 +0000 Received: from int-mx14.intmail.prod.int.phx2.redhat.com (int-mx14.intmail.prod.int.phx2.redhat.com [10.5.11.27]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s6NAjYjM009385 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 23 Jul 2014 06:45:34 -0400 Received: from localhost (ovpn-116-68.ams2.redhat.com [10.36.116.68]) by int-mx14.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id s6NAjXbD030572; Wed, 23 Jul 2014 06:45:34 -0400 Date: Wed, 23 Jul 2014 11:45:32 +0100 From: Jonathan Wakely To: libstdc++@gcc.gnu.org, gcc-patches@gcc.gnu.org Cc: tromey@redhat.com, pmuldoon@redhat.com Subject: Re: [patch] Add libstdc++ pretty printers for Library Fundamentals TS types Message-ID: <20140723104532.GN2361@redhat.com> References: <20140714193130.GH4871@redhat.com> <20140715120322.GM4871@redhat.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20140715120322.GM4871@redhat.com> User-Agent: Mutt/1.5.23 (2014-03-12) On 15/07/14 13:03 +0100, Jonathan Wakely wrote: >On 14/07/14 20:31 +0100, Jonathan Wakely wrote: >>This adds printers for the types in the std::experimental namespace. This should fix the test failures that Paolo and HJ are seeing, older versions of GDB didn't have the gdb.Type.name attribute. (I suppose I could have just put the full basic_string name in explicitly instead of using lookup_type, but I'll just make this fix for now.) Committed to trunk. commit 827e07f7e08bc993a284996f7772b04f82ee7fc9 Author: Jonathan Wakely Date: Wed Jul 23 11:40:02 2014 +0100 * python/libstdcxx/v6/printers.py (StdExpAnyPrinter): Convert type to string instead of using gdb.Type.name attribute. diff --git a/libstdc++-v3/python/libstdcxx/v6/printers.py b/libstdc++-v3/python/libstdcxx/v6/printers.py index 625396b..15d7a88 100644 --- a/libstdc++-v3/python/libstdcxx/v6/printers.py +++ b/libstdc++-v3/python/libstdcxx/v6/printers.py @@ -899,7 +899,7 @@ class StdExpAnyPrinter(SingleObjContainerPrinter): raise ValueError("Unknown manager function in std::experimental::any") # FIXME need to expand 'std::string' so that gdb.lookup_type works - mgrname = re.sub("std::string(?!\w)", gdb.lookup_type('std::string').strip_typedefs().name, m.group(1)) + mgrname = re.sub("std::string(?!\w)", str(gdb.lookup_type('std::string').strip_typedefs()), m.group(1)) mgrtype = gdb.lookup_type(mgrname) self.contained_type = mgrtype.template_argument(0) valptr = None