Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.xs4all.nl!newsfeed3.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.014 X-Spam-Evidence: '*H*': 0.97; '*S*': 0.00; 'debugging': 0.07; 'objects,': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'thus,': 0.09; 'type,': 0.09; 'debugger.': 0.16; 'objects.': 0.16; 'received:80.91.229.3': 0.16; 'received:dip0.t-ipconnect.de': 0.16; 'received:plane.gmane.org': 0.16; 'received:t-ipconnect.de': 0.16; '(in': 0.22; 'header:User-Agent:1': 0.23; 'refers': 0.24; 'header:X-Complaints-To:1': 0.27; 'correct': 0.29; 'possibility': 0.29; 'gives': 0.31; 'usually': 0.31; 'object.': 0.31; 'writes:': 0.31; 'subject:with': 0.35; 'objects': 0.35; 'there': 0.35; 'charset:us-ascii': 0.36; 'level': 0.37; 'to:addr:python-list': 0.38; 'structure': 0.39; 'to:addr:python.org': 0.39; 'received:org': 0.40; 'dave': 0.60; 'no.': 0.61; 'received:217': 0.63; 'show': 0.63; 'information': 0.63; 'such': 0.63; 'field': 0.63; 'refer': 0.63; 'cast': 0.91; 'examine': 0.93 X-Injected-Via-Gmane: http://gmane.org/ To: python-list@python.org From: dieter Subject: Re: Finding referents with Gdb Date: Wed, 01 May 2013 10:33:16 +0200 References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Gmane-NNTP-Posting-Host: pd9e09f92.dip0.t-ipconnect.de User-Agent: Gnus/5.1008 (Gnus v5.10.8) XEmacs/21.4.22 (linux) Cancel-Lock: sha1:pC5jBsrFbuq+rSWk1pnBl9Ek9N0= X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 17 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1367397212 news.xs4all.nl 15992 [2001:888:2000:d::a6]:48083 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:44583 Dave Butler writes: > with gdb, can you find referents of an object given an object id? Usually no. "gdb" is a C level debugger. If debugging information is available (and the type of an object know), "gdb" can show you the fields of an object. If you know the correct type, you can cast an object to this type and get the field information. Thus, "gdb" gives you a possibility to examine the objects, a given object refers to. However, in general, there is no data structure (in a C program) that provides access to the objects that refer to a given object. In such cases, "gdb" cannot help you to find those objects.