From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32377 invoked by alias); 16 Dec 2007 22:00:19 -0000 Received: (qmail 32366 invoked by uid 22791); 16 Dec 2007 22:00:18 -0000 X-Spam-Check-By: sourceware.org Received: from viper.snap.net.nz (HELO viper.snap.net.nz) (202.37.101.8) by sourceware.org (qpsmtpd/0.31) with ESMTP; Sun, 16 Dec 2007 22:00:10 +0000 Received: from kahikatea.snap.net.nz (90.60.255.123.dynamic.snap.net.nz [123.255.60.90]) by viper.snap.net.nz (Postfix) with ESMTP id 5D5FB3DA026; Mon, 17 Dec 2007 11:00:07 +1300 (NZDT) Received: by kahikatea.snap.net.nz (Postfix, from userid 1000) id 095A98FC6D; Mon, 17 Dec 2007 11:00:05 +1300 (NZDT) From: Nick Roberts MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <18277.40933.42208.470774@kahikatea.snap.net.nz> Date: Sun, 16 Dec 2007 22:00:00 -0000 To: Vladimir Prus Cc: gdb@sources.redhat.com Subject: Re: bug in mi when setting breakpoint In-Reply-To: References: <20071216125625.GE4783@coin> <18277.36237.521792.245470@kahikatea.snap.net.nz> X-Mailer: VM 7.19 under Emacs 23.0.50.12 X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2007-12/txt/msg00111.txt.bz2 > > Unfortunately CLI also uses sub-prompts for several other commands: > > queries e.g pending breakpoints, exiting after exevution has started; the > > "commands" command. I don't think that they fit well with the MI > > paradigm: MI expects MI output. With queries, GDB takes affirmative > > action, e.g., creates pending breakpoints regardless of the value of "show > > breakpoint pending" > > I don't think that's true. Week old CVS HEAD won't ever create pending > breakpoint when using MI. Today's CVS HEAD will create pending breakpoint > if you use the -f option to -break-insert. Without that option, pending > breakpoint won't ever be created. It is true with CLI commands in MI: (gdb) -interpreter-exec console "break fgfg" &"Function \"fgfg\" not defined.\n" ~"Breakpoint 1 (fgfg) pending.\n" ^done (gdb) > > and exits regardless of the value of "show confirm". > > > > Perhaps, for now, GDB could do something similar, i.e., set all the > > breakpoints in the breakpoint menu. > > In general, I think that any command that requires any interactivity > should explicitly document how it would handle that. We don't appear to have any provision for such commands in MI and ISTR that Jim Ingham has described difficulties with MI. In, particular they have -break-commands to deal with the "commands" command. I was just proposing a possible immediate fix, not to solve the general problem. -- Nick http://www.inet.net.nz/~nickrob