From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9630 invoked by alias); 10 Nov 2009 22:05:32 -0000 Received: (qmail 9621 invoked by uid 22791); 10 Nov 2009 22:05:32 -0000 X-SWARE-Spam-Status: No, hits=-2.5 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; Tue, 10 Nov 2009 22:05:26 +0000 Received: from int-mx05.intmail.prod.int.phx2.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.18]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id nAAM52fU007379 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 10 Nov 2009 17:05:02 -0500 Received: from ns3.rdu.redhat.com (ns3.rdu.redhat.com [10.11.255.199]) by int-mx05.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id nAAM51xm013384; Tue, 10 Nov 2009 17:05:01 -0500 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 nAAM50ib014631; Tue, 10 Nov 2009 17:05:00 -0500 Received: by opsy.redhat.com (Postfix, from userid 500) id C48663782CF; Tue, 10 Nov 2009 15:04:59 -0700 (MST) From: Tom Tromey To: Hui Zhu Cc: Michael Snyder , Joel Brobecker , "gdb-patches\@sourceware.org" Subject: Re: [RFA] let record_resume fail immediately on error References: <20090928160728.GB9003@adacore.com> <20091015162326.GA5272@adacore.com> <4AD75806.9070705@vmware.com> <4AF07CF2.1050902@vmware.com> Reply-To: Tom Tromey Date: Tue, 10 Nov 2009 22:05:00 -0000 In-Reply-To: (Hui Zhu's message of "Tue, 10 Nov 2009 15:01:54 +0800") 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-11/txt/msg00235.txt.bz2 >>>>> ">" == Hui Zhu writes: >> It add a new argument "catch" to do_record_message. If catch is true, >> it will call "record_message" with catch errors. If not, it will call >> "record_message" directly. I don't like this much either. It is trivial for callers that want to catch errors to catch them. They can use TRY_CATCH or catch_errors(..., record_message). Callers that don't want to catch errors should just call do_record_message directly. This is both for type safety and also because such calls are plain old C, and should therefore look like it. Tom