From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19258 invoked by alias); 18 Sep 2009 16:42:45 -0000 Received: (qmail 19250 invoked by uid 22791); 18 Sep 2009 16:42:44 -0000 X-SWARE-Spam-Status: No, hits=-2.4 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 18 Sep 2009 16:42:36 +0000 Received: from int-mx04.intmail.prod.int.phx2.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.17]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id n8IGfq4M001946; Fri, 18 Sep 2009 12:41:52 -0400 Received: from ns3.rdu.redhat.com (ns3.rdu.redhat.com [10.11.255.199]) by int-mx04.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id n8IGfnwO019973; Fri, 18 Sep 2009 12:41:49 -0400 Received: from opsy.redhat.com (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by ns3.rdu.redhat.com (8.13.8/8.13.8) with ESMTP id n8IGfmLU003558; Fri, 18 Sep 2009 12:41:51 -0400 Received: by opsy.redhat.com (Postfix, from userid 500) id 0F33B378204; Fri, 18 Sep 2009 10:41:48 -0600 (MDT) From: Tom Tromey To: Marc Khouzam Cc: "'Joel Brobecker'" , "'gdb-patches\@sourceware.org'" Subject: Re: Another proposal for frontends and queries. References: <20090916214051.GF8910@adacore.com> Reply-To: Tom Tromey Date: Fri, 18 Sep 2009 16:42:00 -0000 In-Reply-To: (Marc Khouzam's message of "Fri, 18 Sep 2009 10:55:26 -0400") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2009-09/txt/msg00601.txt.bz2 >>>>> "Marc" == Marc Khouzam writes: Marc> The last (I think :-)) part that I don't understand is if a FE must Marc> code in advance for a potential query? This solution seems to go Marc> towards a way that would allow a FE to be ready for any query Marc> on any command. A new query could be added to a command by a new GDB Marc> version, and FEs would not need to change. That would be nice. Marc> Is that how you see it? Yeah -- a front end could choose what to do, even present the query to the user. Marc> I'm asking because, in some case a FE Marc> will want to answer the query itself, without seeking input from the user. Marc> For example, for PRecord, when the query asks if we should allow to change Marc> memory, I won't ask the user, I just want to say 'y'. Marc> I don't see how a FE could be smart enough to generically answer Marc> queries like that? (unless we code for it in advance) Yeah, good point. This seems to imply that the query "error" should include a token naming the query -- and I guess that such tokens should remain stable over time. (I was hoping to avoid that...) Marc> On the flip side, if a FE knows in advance the potential queries Marc> to a specific command, then maybe all we need is some new MI general Marc> parameter "-query " that could be added by the frontend Marc> to any command (some details would need to be worked out to handle Marc> multiple queries in the same command though). Marc> Does this make sense? Yes, except that the queries could also change over time. I'm not sure this is a great idea after all. Maybe the solution is really just to have all queries default to "go ahead and do it" in MI. I really don't know. Tom