From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8579 invoked by alias); 10 May 2012 17:19:22 -0000 Received: (qmail 8571 invoked by uid 22791); 10 May 2012 17:19:21 -0000 X-SWARE-Spam-Status: No, hits=-1.9 required=5.0 tests=AWL,BAYES_00,RCVD_IN_HOSTKARMA_NO,TW_BJ X-Spam-Check-By: sourceware.org Received: from rock.gnat.com (HELO rock.gnat.com) (205.232.38.15) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 10 May 2012 17:19:06 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by filtered-rock.gnat.com (Postfix) with ESMTP id 288C51C6B82; Thu, 10 May 2012 13:19:06 -0400 (EDT) Received: from rock.gnat.com ([127.0.0.1]) by localhost (rock.gnat.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id qPf1Ok8IQbQj; Thu, 10 May 2012 13:19:02 -0400 (EDT) Received: from joel.gnat.com (localhost.localdomain [127.0.0.1]) by rock.gnat.com (Postfix) with ESMTP id C486F1C6B7A; Thu, 10 May 2012 13:19:02 -0400 (EDT) Received: by joel.gnat.com (Postfix, from userid 1000) id 5425B145616; Thu, 10 May 2012 10:18:53 -0700 (PDT) Date: Thu, 10 May 2012 17:19:00 -0000 From: Joel Brobecker To: Tom Tromey Cc: gdb-patches@sourceware.org Subject: Re: [RFA] choose symbol from given block's objfile first. Message-ID: <20120510171853.GS15555@adacore.com> References: <1336430581-11262-1-git-send-email-brobecker@adacore.com> <874nrqvbeh.fsf@fleche.redhat.com> <20120509190529.GI15555@adacore.com> <20120509190753.GA31769@adacore.com> <87ehqtru0d.fsf@fleche.redhat.com> <20120509204023.GM15555@adacore.com> <87lil1qdin.fsf@fleche.redhat.com> <20120509210526.GP15555@adacore.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20120509210526.GP15555@adacore.com> User-Agent: Mutt/1.5.20 (2009-06-14) 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 X-SW-Source: 2012-05/txt/msg00372.txt.bz2 > > I'm not so sure. It seems like you could make a multi-objfile test case > > where an incomplete type is incorrectly resolved to a type in another > > objfile. I created a PR for that: http://sourceware.org/bugzilla/show_bug.cgi?id=14093 I noted in the PR description that applying the same treatment as what we did here would not be sufficient if the same type name is used twice in the same objfile for two distinct types. In that case, I don't know if there is really a solution other than forcing the user to cast the result to a type using an expression that includes sufficient information to pick the correct one. -- Joel