From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27118 invoked by alias); 15 Nov 2006 01:23:15 -0000 Received: (qmail 27105 invoked by uid 22791); 15 Nov 2006 01:23:14 -0000 X-Spam-Check-By: sourceware.org Received: from ns.suse.de (HELO mx1.suse.de) (195.135.220.2) by sourceware.org (qpsmtpd/0.31) with ESMTP; Wed, 15 Nov 2006 01:23:05 +0000 Received: from Relay2.suse.de (mail2.suse.de [195.135.221.8]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.suse.de (Postfix) with ESMTP id 3AF3611E0F; Wed, 15 Nov 2006 02:23:03 +0100 (CET) From: Andreas Schwab To: "Peng Yu" Cc: gdb@sourceware.org Subject: Re: How to debug C++ functor in gdb? References: <366c6f340610291301p523de441r6b691975822a9131@mail.gmail.com> <366c6f340611141612s2ccd04d0i826c5c8253ec74d@mail.gmail.com> X-Yow: I just bought FLATBUSH from MICKEY MANTLE! Date: Wed, 15 Nov 2006 01:23:00 -0000 In-Reply-To: <366c6f340611141612s2ccd04d0i826c5c8253ec74d@mail.gmail.com> (Peng Yu's message of "Tue, 14 Nov 2006 18:12:34 -0600") Message-ID: User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2006-11/txt/msg00091.txt.bz2 "Peng Yu" writes: > On 10/29/06, Andreas Schwab wrote: >> "Peng Yu" writes: >> >> > I set a break point at the line indicated in the comment. Then I call >> > the following command in gdb. It failed. Is there any way that I can >> > call the functor _f? >> > >> > (gdb) p _f(10) >> > Couldn't find method functor >::_f >> >> (gdb) p _f.'operator()'(10) >> $1 = 10 >> >> Andreas. > > Hi, > > Is it syntax described in the manual somewhere? operator() is normal C++ syntax. Andreas. -- Andreas Schwab, SuSE Labs, schwab@suse.de SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany PGP key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5 "And now for something completely different."