From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id E73C0385828E; Wed, 6 Sep 2023 13:04:04 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E73C0385828E DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1694005444; bh=H6XBmARFzoOAcpoQlB0YzRIdCuSQTwWA0kmgLSdGxb8=; h=From:To:Subject:Date:In-Reply-To:References:From; b=kA/TOsPQH7Jatwc9mSZ0fWVhZmmYyVOsC8NSsVGYLAOH5Z40wb9aSQqHINVvyjLiH yiOD2nooKauPiuyxhMncoff4dfISSsUiHOo7uITZ5HShj/jiaSG7WgOcMEgXg8dXj8 uDA4yg6BjvWulwfznrby0B1tK3z2UP3xXUQj/U+c= From: "vries at gcc dot gnu.org" To: gdb-prs@sourceware.org Subject: [Bug ada/30726] [gdb/ada, cc-with-dwz] FAIL: gdb.ada/arr_acc_idx_w_gap.exp: enum_rep Date: Wed, 06 Sep 2023 13:04:04 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gdb X-Bugzilla-Component: ada X-Bugzilla-Version: HEAD X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: vries at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://sourceware.org/bugzilla/show_bug.cgi?id=3D30726 --- Comment #4 from Tom de Vries --- Fixed by: ... diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c index c0cc512bfa3..5b8b54331b7 100644 --- a/gdb/ada-lang.c +++ b/gdb/ada-lang.c @@ -5104,7 +5104,8 @@ remove_extra_symbols (std::vector &syms) to ask the user to disambiguate anyways. And if we have to present a multiple-choice menu, it's less confusing if the list isn't missing some choices that were identical and yet distinct. */ - if (symbols_are_identical_enums (syms)) + if (false && symbols_are_identical_enums (syms)) syms.resize (1); } ... Here in remove_extra_symbols we randomly throw away one of the two enums. In the cc-with-dwz variant, we throw away the wrong one because the order in which the symbols is found has changed. If there are two symbols remaining after remove_extra_symbols, write_var_or_type produces an ambiguous var, which then allows the ada_pop here: ... | type_prefix TICK_ENUM_REP '(' exp ')' { operation_up arg =3D ada_pop (true, $1); pstate->push_new ($1, std::move (arg)); } ... to resolve the literal using the $1 context_type. --=20 You are receiving this mail because: You are on the CC list for the bug.=