From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id E90123858C5F; Fri, 26 May 2023 19:28:55 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E90123858C5F DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1685129335; bh=kDGLMA5XDAvcAXyOG8sGb6OaZnxqQ0B/grGP4qmYpDw=; h=From:To:Subject:Date:In-Reply-To:References:From; b=Fc1RkMIfthEqTl0ZDEsgSOu8CvAFGKtEDqs5Q2UQ+w/O8FHfG5JmqZmRVuAvgKvmJ wwVRYh84JowbhkPbNmTCirvr17Sx+yUkmnygtlQYHgt++NZC3volsw6t980sEjsYPQ RgqZMP9qRd0eHNbT9y5gdhVPcCgvgTS9ZgeFWkyg= From: "tromey at sourceware dot org" To: gdb-prs@sourceware.org Subject: [Bug python/30489] gdb.Type.template_argument issue when using __int128 unsigned Date: Fri, 26 May 2023 19:28:55 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gdb X-Bugzilla-Component: python X-Bugzilla-Version: 13.1 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: tromey at sourceware dot 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=3D30489 --- Comment #3 from Tom Tromey --- Ok, thanks, I think I see the problem now. The "syntax error" means that gdb is falling back on the old-style name-parsing approach to extracting template parameters. This method shouldn't really be needed with contemporary compilers, though. So digging a bit deeper & looking at the DWARF, the type of a variant in my test program is: <2>: Abbrev Number: 56 (DW_TAG_class_type) DW_AT_name : (indirect string, offset: 0x1216): variant<__int128 unsigned, char const*> [...] <3>: Abbrev Number: 12 (DW_TAG_GNU_template_parameter_pack) DW_AT_name : (indirect string, offset: 0x21b1): _Types <4>: Abbrev Number: 3 (DW_TAG_template_type_param) DW_AT_type : <0x14a9> <4>: Abbrev Number: 3 (DW_TAG_template_type_param) DW_AT_type : <0x1532> I suspect what is going on is that the Python code doesn't understand parameter packs; or that maybe these aren't registered with the type in a usable way. --=20 You are receiving this mail because: You are on the CC list for the bug.=