From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id CbduGNv/Amp9YTMAWB0awg (envelope-from ) for ; Tue, 12 May 2026 06:24:27 -0400 Authentication-Results: simark.ca; dkim=pass (1024-bit key; unprotected) header.d=suse.de header.i=@suse.de header.a=rsa-sha256 header.s=susede2_rsa header.b=KwG3F9/2; dkim=pass header.d=suse.de header.i=@suse.de header.a=ed25519-sha256 header.s=susede2_ed25519 header.b=bPZxjWLL; dkim=pass (1024-bit key) header.d=suse.de header.i=@suse.de header.a=rsa-sha256 header.s=susede2_rsa header.b=KwG3F9/2; dkim=neutral header.d=suse.de header.i=@suse.de header.a=ed25519-sha256 header.s=susede2_ed25519 header.b=bPZxjWLL; dkim-atps=neutral Received: by simark.ca (Postfix, from userid 112) id 5E4051E0C3; Tue, 12 May 2026 06:24:27 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-2.4 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_00, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED,RCVD_IN_VALIDITY_CERTIFIED_BLOCKED, RCVD_IN_VALIDITY_RPBL_BLOCKED,RCVD_IN_VALIDITY_SAFE_BLOCKED autolearn=ham autolearn_force=no version=4.0.1 Received: from vm01.sourceware.org (vm01.sourceware.org [38.145.34.32]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id 7CF431E093 for ; Tue, 12 May 2026 06:24:26 -0400 (EDT) Received: from vm01.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 1D04E4B99F50 for ; Tue, 12 May 2026 10:24:26 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1D04E4B99F50 Authentication-Results: sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=suse.de header.i=@suse.de header.a=rsa-sha256 header.s=susede2_rsa header.b=KwG3F9/2; dkim=pass header.d=suse.de header.i=@suse.de header.a=ed25519-sha256 header.s=susede2_ed25519 header.b=bPZxjWLL; dkim=pass (1024-bit key) header.d=suse.de header.i=@suse.de header.a=rsa-sha256 header.s=susede2_rsa header.b=KwG3F9/2; dkim=neutral header.d=suse.de header.i=@suse.de header.a=ed25519-sha256 header.s=susede2_ed25519 header.b=bPZxjWLL Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.223.131]) by sourceware.org (Postfix) with ESMTPS id 1F5624B9DB5F for ; Tue, 12 May 2026 10:22:38 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 1F5624B9DB5F Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=suse.de Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.de ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 1F5624B9DB5F Authentication-Results: sourceware.org; arc=none smtp.remote-ip=195.135.223.131 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1778581358; cv=none; b=f1X34y1buX5AAXaBaugTiDHdjSHmyWM6fLnMQ8+6KYDxKoocQOoqnuLvdNlHPzOUK2afggHSzDx4kmU8WnQx1uj9+F2vG6z0ZkXAbJsdYl3ZaHOe9BxcfQ4uPUkVrr7JibJDlddGFGT36QStJ1vASo9cdyI0xBolNcaKu8TGp50= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1778581358; c=relaxed/simple; bh=KyWmdaM3UuJ2BG+e/pUeQV9crBsykMIgiNksCPqlAlk=; h=DKIM-Signature:DKIM-Signature:DKIM-Signature:DKIM-Signature: Message-ID:Date:MIME-Version:Subject:To:From; b=Xu9B1Q3HXS872QhM4YsvK/pqIR5ohlwrH9bqSKU2fyhdPhWdu1CbNkU/y6Rw3leSleE+ubAjiAAIz2lZQFHV+fDms2u5j3ToCy5GpKQf4CopR6pS+Nyfs1bGFcQRekrZ0gFc7HmuBPo9an/UqvDra+u6J2l8lT4i85X8E+41ITk= ARC-Authentication-Results: i=1; sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=suse.de header.i=@suse.de header.a=rsa-sha256 header.s=susede2_rsa header.b=KwG3F9/2; dkim=pass header.d=suse.de header.i=@suse.de header.a=ed25519-sha256 header.s=susede2_ed25519 header.b=bPZxjWLL; dkim=pass (1024-bit key) header.d=suse.de header.i=@suse.de header.a=rsa-sha256 header.s=susede2_rsa header.b=KwG3F9/2; dkim=neutral header.d=suse.de header.i=@suse.de header.a=ed25519-sha256 header.s=susede2_ed25519 header.b=bPZxjWLL DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1F5624B9DB5F Received: from imap1.dmz-prg2.suse.org (imap1.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 1AE1875DD4; Tue, 12 May 2026 10:22:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1778581357; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=fN6gAd6we4r1IntUahoEl+AIFmW5nrC78wyTM11z7is=; b=KwG3F9/2AE2kuT6Uubw9AmBmCJ3KCVVzrLxFkchXg2R9T1GfBVQAd52htSu19Nu0EcswBu MuuIz4sdNlNGlz3uiKhLAtEpL+raRkAWS7g4uZ+s3ex1FOh+PIizXcW44inQxKoMVgkJTD Ld6pWQVxlYOJSMFm6Nu/3b/71ieAZJw= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1778581357; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=fN6gAd6we4r1IntUahoEl+AIFmW5nrC78wyTM11z7is=; b=bPZxjWLLtngQcFLGzuh3EnJUCLOMl+2TXURb1DzIh1OFodChthoYHPjWAT12PBY67VR03B OmvyiH914se/xKCA== Authentication-Results: smtp-out2.suse.de; dkim=pass header.d=suse.de header.s=susede2_rsa header.b="KwG3F9/2"; dkim=pass header.d=suse.de header.s=susede2_ed25519 header.b=bPZxjWLL DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1778581357; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=fN6gAd6we4r1IntUahoEl+AIFmW5nrC78wyTM11z7is=; b=KwG3F9/2AE2kuT6Uubw9AmBmCJ3KCVVzrLxFkchXg2R9T1GfBVQAd52htSu19Nu0EcswBu MuuIz4sdNlNGlz3uiKhLAtEpL+raRkAWS7g4uZ+s3ex1FOh+PIizXcW44inQxKoMVgkJTD Ld6pWQVxlYOJSMFm6Nu/3b/71ieAZJw= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1778581357; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=fN6gAd6we4r1IntUahoEl+AIFmW5nrC78wyTM11z7is=; b=bPZxjWLLtngQcFLGzuh3EnJUCLOMl+2TXURb1DzIh1OFodChthoYHPjWAT12PBY67VR03B OmvyiH914se/xKCA== Received: from imap1.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap1.dmz-prg2.suse.org (Postfix) with ESMTPS id 00AB1593A9; Tue, 12 May 2026 10:22:36 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap1.dmz-prg2.suse.org with ESMTPSA id 9EZeOmz/AmrJbAAAD6G6ig (envelope-from ); Tue, 12 May 2026 10:22:36 +0000 Message-ID: Date: Tue, 12 May 2026 12:22:36 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v5 3/3] [gdb/exp] Handle recursive namespace import To: Tom Tromey Cc: gdb-patches@sourceware.org References: <20260419081236.570600-1-tdevries@suse.de> <20260419081236.570600-4-tdevries@suse.de> <875x56hqek.fsf@tromey.com> Content-Language: en-US From: Tom de Vries In-Reply-To: <875x56hqek.fsf@tromey.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Rspamd-Action: no action X-Spamd-Result: default: False [-4.51 / 50.00]; BAYES_HAM(-3.00)[99.99%]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_SHORT(-0.20)[-1.000]; R_DKIM_ALLOW(-0.20)[suse.de:s=susede2_rsa,suse.de:s=susede2_ed25519]; MIME_GOOD(-0.10)[text/plain]; MX_GOOD(-0.01)[]; RCVD_TLS_ALL(0.00)[]; FUZZY_RATELIMITED(0.00)[rspamd.com]; RCVD_VIA_SMTP_AUTH(0.00)[]; MIME_TRACE(0.00)[0:+]; ARC_NA(0.00)[]; TO_DN_SOME(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; RCPT_COUNT_TWO(0.00)[2]; DKIM_SIGNED(0.00)[suse.de:s=susede2_rsa,suse.de:s=susede2_ed25519]; FROM_EQ_ENVFROM(0.00)[]; FROM_HAS_DN(0.00)[]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:97:from]; RCVD_COUNT_TWO(0.00)[2]; TO_MATCH_ENVRCPT_ALL(0.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[imap1.dmz-prg2.suse.org:rdns,imap1.dmz-prg2.suse.org:helo,suse.de:dkim,suse.de:email,suse.de:mid,sourceware.org:url]; DNSWL_BLOCKED(0.00)[2a07:de40:b281:104:10:150:64:97:from,2a07:de40:b281:106:10:150:64:167:received]; DKIM_TRACE(0.00)[suse.de:+] X-Rspamd-Queue-Id: 1AE1875DD4 X-Rspamd-Server: rspamd2.dmz-prg2.suse.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~public-inbox=simark.ca@sourceware.org On 5/1/26 9:37 PM, Tom Tromey wrote: >>>>>> "Tom" == Tom de Vries writes: > > Tom> Fix this by additionally iterating over the super blocks instead of only using > Tom> the current block. > > FWIW I haven't really commented much on the core part of this series > because I find this code pretty confusing and I'm not really sure I > understand it well enough to do a good job reviewing it. > > Tom> + for (const struct block *b = block; b != nullptr; > Tom> + b = b->superblock ()) > Tom> + cp_lookup_symbol_via_imports (current->import_src, name, > Tom> + b, domain, 1, 0, 0, > > In this spot, suppose 'block' is from an inlined function. Then when > iterating, I think we'll end up seeing blocks from the enclosing > function (the one that was inlined-into). However, that could yield the > wrong result, because the inlined and inlined-into functions could come > from completely different namespace contexts with different 'using' > directives. Thanks for pointing this out, fixed in a v6 ( https://sourceware.org/pipermail/gdb-patches/2026-May/227330.html ). Thanks, - Tom