From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30956 invoked by alias); 15 Jan 2010 16:35:04 -0000 Mailing-List: contact archer-help@sourceware.org; run by ezmlm Sender: Precedence: bulk List-Post: List-Help: List-Subscribe: List-Id: Received: (qmail 30946 invoked by uid 22791); 15 Jan 2010 16:35:03 -0000 X-SWARE-Spam-Status: No, hits=-2.5 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: sourceware.org Message-ID: <4B50992F.3080908@redhat.com> Date: Fri, 15 Jan 2010 16:35:00 -0000 From: Phil Muldoon User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.5) Gecko/20091209 Fedora/3.0-4.fc12 Lightning/1.0pre Thunderbird/3.0 MIME-Version: 1.0 To: Project Archer Subject: Question on pr python/11060 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-SW-Source: 2010-q1/txt/msg00014.txt.bz2 http://sourceware.org/bugzilla/show_bug.cgi?id=11060 I believe this is happening as DEMANGLE_COMPONENT_LITERAL is not being accounted for in the type lookup. In this case of a template argument resolving to LITERAL, is it ok just to return the type backing the argument without further manipulation? I spent a few hours this morning looking for side-effects but came up blank. Types seems to resolve as expected (ie in the <42> case it is an int type). Thoughts? Rough patch: diff --git a/gdb/python/py-type.c b/gdb/python/py-type.c index a97c125..bcd3f4f 100644 --- a/gdb/python/py-type.c +++ b/gdb/python/py-type.c @@ -475,7 +475,8 @@ typy_lookup_type (struct demangle_component *demangled) if (demangled_type == DEMANGLE_COMPONENT_POINTER || demangled_type == DEMANGLE_COMPONENT_REFERENCE || demangled_type == DEMANGLE_COMPONENT_CONST - || demangled_type == DEMANGLE_COMPONENT_VOLATILE) + || demangled_type == DEMANGLE_COMPONENT_VOLATILE + || demangled_type == DEMANGLE_COMPONENT_LITERAL) { type = typy_lookup_type (demangled->u.s_binary.left); if (! type) @@ -491,6 +492,8 @@ typy_lookup_type (struct demangle_component *demangled) return make_cv_type (1, 0, type, NULL); case DEMANGLE_COMPONENT_VOLATILE: return make_cv_type (0, 1, type, NULL); + case DEMANGLE_COMPONENT_LITERAL: + return type; } }