From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 62322383E82B; Thu, 21 Jan 2021 19:27:40 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 62322383E82B From: "malcolm.parsons at gmail dot com" To: gdb-prs@sourceware.org Subject: [Bug python/13326] Need support for C++ method call for a gdb.Value object from within python Date: Thu, 21 Jan 2021 19:27:40 +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: 7.3 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: malcolm.parsons at gmail dot com 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: cc 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 X-BeenThere: gdb-prs@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-prs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 21 Jan 2021 19:27:40 -0000 https://sourceware.org/bugzilla/show_bug.cgi?id=3D13326 Malcolm Parsons changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |malcolm.parsons at gmail d= ot com --- Comment #3 from Malcolm Parsons --- Use from a python pretty-printer is a bit convoluted, but it works: def to_string(self): gdb.set_convenience_variable('_tmp', self.val.reference_value()) return gdb.parse_and_eval('$_tmp.str()') --=20 You are receiving this mail because: You are on the CC list for the bug.=