From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6787 invoked by alias); 12 Sep 2002 22:16:29 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 6777 invoked from network); 12 Sep 2002 22:16:28 -0000 Received: from unknown (HELO localhost.redhat.com) (216.138.202.10) by sources.redhat.com with SMTP; 12 Sep 2002 22:16:28 -0000 Received: from ges.redhat.com (localhost [127.0.0.1]) by localhost.redhat.com (Postfix) with ESMTP id 2E5D93C44; Thu, 12 Sep 2002 18:16:25 -0400 (EDT) Message-ID: <3D811239.3080302@ges.redhat.com> Date: Thu, 12 Sep 2002 15:16:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD macppc; en-US; rv:1.0.0) Gecko/20020824 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Kevin Buettner Cc: gdb-patches@sources.redhat.com Subject: Re: [PING] ui_out related patches References: <1020907001738.ZM27333@localhost.localdomain> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2002-09/txt/msg00220.txt.bz2 > Could someone please take a look at the following patches: > > http://sources.redhat.com/ml/gdb-patches/2002-07/msg00514.html > http://sources.redhat.com/ml/gdb-patches/2002-07/msg00517.html > > They are both related to internal errors that occur when gdb generates > a long list and the user aborts in the midst of displaying the list. > > IMO, this is something that should be fixed prior to the next release. (I accidently deleted the other thread discussing this.) Anyway, 1.3c worth ... Way back when MI was being started one of the ``lofty goals'' was to eliminate the exception code (i.e., cleanups, everything would use return). I think reality has set in on this front and we're not going to manage it --- instead we're going to be living with cleanups for a long time. Anyway, I think the code should be made more robust. That is, given: ui_out_cleanup_list_begin() ui_out_tupple_begin() ui_out_list_begin() ui_out_list_end() ui_out_tupple_end() do_cleanups (list_end_cleanup); the cleanup should know how to close off everything back to the specified cleanup level. Other approaches would be: cleanup = make_cleanup (null_cleanup, NULL); ui_out_cleanup_list_begin() ui_out_cleanup_tupple_begin() ui_out_cleanup_list_begin() do_cleanups (list_end_cleanup); which happens to ``work'' (cleanups are a filo). And even: ui_out_list_begin() ui_out_tupple_begin() ui_out_list_begin() ui_out_list_end() ui_out_tupple_end() ui_out_list_end() where ui-out internally and implicitly set up and executed cleanups. Andrew