From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27299 invoked by alias); 14 May 2013 09:36:04 -0000 Mailing-List: contact gdb-prs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-prs-owner@sourceware.org Received: (qmail 27233 invoked by uid 48); 14 May 2013 09:36:04 -0000 From: "andre.poenitz at digia dot com" To: gdb-prs@sourceware.org Subject: [Bug python/15464] New: Accessing anonymous unions from Python Date: Tue, 14 May 2013 09:36:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gdb X-Bugzilla-Component: python X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: andre.poenitz at digia dot com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Message-ID: X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 X-SW-Source: 2013-q2/txt/msg00258.txt.bz2 http://sourceware.org/bugzilla/show_bug.cgi?id=15464 Bug #: 15464 Summary: Accessing anonymous unions from Python Product: gdb Version: unknown Status: NEW Severity: normal Priority: P2 Component: python AssignedTo: unassigned@sourceware.org ReportedBy: andre.poenitz@digia.com Classification: Unclassified If I have a struct X { union { Y y; Z z; } } x; and later a = gdb.parse_and_eval("x") there seems to be no easy way to access the "union" "level". 'a' itself is the struct, 'a["y"]' transparently skips the union and gives the named member. It would be nice if there was a way to iterate through the children of the struct. MI/varobjs nowaday seem to have that ability. -- Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.