From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6783 invoked by alias); 22 Apr 2002 20:13:41 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 6771 invoked from network); 22 Apr 2002 20:13:38 -0000 Received: from unknown (HELO odin.inter.net.il) (192.114.186.10) by sources.redhat.com with SMTP; 22 Apr 2002 20:13:38 -0000 Received: from Zaretsky ([80.230.2.40]) by odin.inter.net.il (Mirapoint Messaging Server MOS 2.9.3.2) with ESMTP id ABO89709; Mon, 22 Apr 2002 23:13:26 +0300 (IDT) Date: Mon, 22 Apr 2002 13:13:00 -0000 From: "Eli Zaretskii" To: tromey@redhat.com Message-Id: <2593-Mon22Apr2002231326+0300-eliz@is.elta.co.il> CC: gdb@sources.redhat.com In-reply-to: <87d6wrmsdt.fsf@creche.redhat.com> (message from Tom Tromey on 22 Apr 2002 13:43:10 -0600) Subject: Re: confusion in the `b' command Reply-to: Eli Zaretskii References: <87d6wrmsdt.fsf@creche.redhat.com> X-SW-Source: 2002-04/txt/msg00367.txt.bz2 > From: Tom Tromey > Date: 22 Apr 2002 13:43:10 -0600 > > Now try to set a breakpoint like this: > > b 'x.main > > gdb just beeps at me. What version of GDB is that? Head? branch? released version? > So close the quotes and press enter: > > (gdb) b 'x.main' > the class x does not have any method named main > Hint: try 'x.main' or 'x.main' > (Note leading single quote.) > > Now try again: > > b 'x.main > > I get: > > (gdb) b 'x.main(java.lang.String[])' > > I think this must be a bug. I expected: > > * First, that TAB would work correctly the first time. This is probably another manifestation of a known problem with completion: different types of objects (files, symbols, commands, etc.) need different sets of delimiter characters to make completion DTRT, but Readline doesn't give GDB a chance to set the delimiters before the first completion attempt. Thus, GDB gets the user input after breakup into words, but the notion of ``a word'' does not match what it should be for the object on which GDB is completing. We currently try to work around this nuisance, but there's no way to do that for the first completion attempt on a given object type.z What we need is a hook from Readline that would be called _before_ Readline breaks up input into ``words''. > * Second, that b 'x.main' would work anyway, since it is unambiguous. I'm not sure what you mean here. Do you mean that GDB shouldn't have forced you to quote the string "x.main(java.lang.String[])"?