From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10682 invoked by alias); 15 Apr 2010 14:35:56 -0000 Received: (qmail 10667 invoked by uid 48); 15 Apr 2010 14:35:56 -0000 Date: Thu, 15 Apr 2010 14:35:00 -0000 Message-ID: <20100415143556.10666.qmail@sourceware.org> From: "michel dot metzger at st dot com" To: gdb-prs@sourceware.org In-Reply-To: <20100409172931.11482.michel.metzger@st.com> References: <20100409172931.11482.michel.metzger@st.com> Reply-To: sourceware-bugzilla@sourceware.org Subject: [Bug python/11482] Side effect of set print address on python API X-Bugzilla-Reason: CC 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 X-SW-Source: 2010-q2/txt/msg00102.txt.bz2 ------- Additional Comments From michel dot metzger at st dot com 2010-04-15 14:35 ------- I perfectly understand how set print address works and what it's used for. Let me explain with more details what I'm trying to achieve. Maybe I'm doing this completely wrong. I'm developing new commands to ease the debugging of applications developed using component-oriented programming. I want to write a command that will print, using the value of the "this" pointer, the actual name of the instance. To do that I have a table, in python, of all instances (more or less like OOP instances), indexed with their location in memory. Since gdb.Value is not hashable, so there is no way to use it directly as a key. So the solution I implemented was to use the string representing the address as a key in my hashtable. As you can see, I'm not trying to print any address, just use them internally in the command implementation. I hope this will makes things clearer. -- http://sourceware.org/bugzilla/show_bug.cgi?id=11482 ------- You are receiving this mail because: ------- You are on the CC list for the bug, or are watching someone who is.