From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15428 invoked by alias); 5 Apr 2012 19:56:25 -0000 Received: (qmail 15417 invoked by uid 22791); 5 Apr 2012 19:56:24 -0000 X-SWARE-Spam-Status: No, hits=-4.7 required=5.0 tests=AWL,BAYES_00,KHOP_RCVD_UNTRUST,KHOP_THREADED,RCVD_IN_DNSWL_HI,RCVD_IN_HOSTKARMA_W,T_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; Thu, 05 Apr 2012 19:56:11 +0000 X-Loopcount0: from 10.170.28.39 From: To: , Date: Thu, 05 Apr 2012 19:56:00 -0000 Subject: RE: [RFC - Python Scripting] New method Objfile.symtabs () - docs included Message-ID: <09787EF419216C41A903FD14EE5506DD0313D5C22C@AUSX7MCPC103.AMER.DELL.COM> References: In-Reply-To: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2012-04/txt/msg00082.txt.bz2 In this patch, you have an iterator that walks over the symtabs for an objf= ile, but that is only used internally in the symtabs() method which is writ= ten to return a list. How about having symtabs() return the iterator instead? An iterator is usu= ally just as good as a list (and more efficient); in the rare cases where y= ou actually need the list, simply doing list(objfile.symtabs()) will do tha= t. paul