From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25669 invoked by alias); 16 Aug 2011 11:04:05 -0000 Received: (qmail 25661 invoked by uid 22791); 16 Aug 2011 11:04:03 -0000 X-SWARE-Spam-Status: No, hits=-2.3 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from ausxipps301.us.dell.com (HELO ausxipps301.us.dell.com) (143.166.148.223) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 16 Aug 2011 11:03:48 +0000 X-Loopcount0: from 10.175.216.249 From: To: Date: Tue, 16 Aug 2011 11:04:00 -0000 Subject: Some Python ideas, looking for feedback Message-ID: <09787EF419216C41A903FD14EE5506DD0151D583A2@AUSX7MCPC103.AMER.DELL.COM> Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2011-08/txt/msg00058.txt.bz2 In trying out the Python scripting, I've run into some things that seem eit= her inconsistent, or omissions of standard Python facilities, and I could d= o something about this if there is interest. One inconsistency: Value objects can have their fields looked up by collect= ion syntax, but Type objects cannot.=A0=20 Omission: while Value objects can have collection references to individual = components, they don't support iteration as is normal for Python collection= s. And a question: is there a way to get the value corresponding to an enum ty= pe's value name? =A0The name comes back in the fields() output but I don't = see how I would get the value.=A0 Could that be made a value attribute of t= he field object? I can propose patches for each of these things, if there is interest. =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 paul