From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14415 invoked by alias); 25 May 2003 23:16:42 -0000 Mailing-List: contact guile-gtk-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: guile-gtk-owner@sources.redhat.com Received: (qmail 14399 invoked from network); 25 May 2003 23:16:41 -0000 Received: from unknown (HELO snoopy.pacific.net.au) (61.8.0.36) by sources.redhat.com with SMTP; 25 May 2003 23:16:41 -0000 Received: from sunny.pacific.net.au (sunny.pacific.net.au [203.2.228.40]) by snoopy.pacific.net.au (8.12.3/8.12.3/Debian-6.3) with ESMTP id h4PNGSPB027324; Mon, 26 May 2003 09:16:28 +1000 Received: from wisma.pacific.net.au (wisma.pacific.net.au [210.23.129.72]) by sunny.pacific.net.au with ESMTP id h4PNGSQg005223; Mon, 26 May 2003 09:16:28 +1000 (EST) Received: from localhost (ppp29.dyn228.pacific.net.au [203.143.228.29]) by wisma.pacific.net.au (8.12.9/8.12.9) with ESMTP id h4PNGPYZ009462; Mon, 26 May 2003 09:16:26 +1000 (EST) Received: from gg by localhost with local (Exim 3.35 #1 (Debian)) id 19K4iv-0000PK-00; Mon, 26 May 2003 09:16:17 +1000 To: Andy Wingo Cc: guile-gtk@sources.redhat.com Subject: Re: GError References: <20030524113300.GB24132@lark> From: Kevin Ryde Mail-Copies-To: never Date: Sun, 25 May 2003 23:16:00 -0000 In-Reply-To: <20030524113300.GB24132@lark> (Andy Wingo's message of "Sat, 24 May 2003 12:33:00 +0100") Message-ID: <87addamxbz.fsf@zip.com.au> User-Agent: Gnus/5.090019 (Oort Gnus v0.19) Emacs/21.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2003-q2/txt/msg00109.txt.bz2 Andy Wingo writes: > > With regards to GError, I think the solution you propose is too much > like C programming. Oh, well, if it's nice and close then at least people familiar with the C style will find the guile interface comfortingly similar. Or vice versa even. > Wouldn't it be nicer if, instead of forcing the > programmer to know about GErrors, if we simply threw an exception if the > GError is set? Perhaps make the gerror parameter optional, if omitted an error is thrown. Or a special value 'error or something to mean that. That could allow a choice between programming in typical glib style (check return values) or more typical guile style (file i/o throws exceptions).