From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Han-Wen Nienhuys Newsgroups: gmane.lisp.guile.user Subject: Re: C++ declaration style programming? Date: Wed, 21 Jan 2004 13:40:42 +0100 Sender: guile-user-bounces+guile-user=m.gmane.org@gnu.org Message-ID: <16398.29514.719974.994390@localhost.localdomain> References: <16397.43262.881852.180514@localhost.localdomain> <16397.63705.338864.586672@shmyh.ua> Reply-To: hanwen@cs.uu.nl NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1074688948 4345 80.91.224.253 (21 Jan 2004 12:42:28 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 21 Jan 2004 12:42:28 +0000 (UTC) Cc: guile-user@gnu.org Original-X-From: guile-user-bounces+guile-user=m.gmane.org@gnu.org Wed Jan 21 13:42:20 2004 Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1AjHgZ-0001A1-00 for ; Wed, 21 Jan 2004 13:42:20 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.24) id 1AjHfl-00042m-SW for guile-user@m.gmane.org; Wed, 21 Jan 2004 07:41:29 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.24) id 1AjHe9-00041P-JW for guile-user@gnu.org; Wed, 21 Jan 2004 07:39:49 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.24) id 1AjHdc-0003uH-RW for guile-user@gnu.org; Wed, 21 Jan 2004 07:39:47 -0500 Original-Received: from [213.84.26.127] (helo=localhost.localdomain) by monty-python.gnu.org with esmtp (TLSv1:DES-CBC3-SHA:168) (Exim 4.24) id 1AjHdb-0003tt-Ts for guile-user@gnu.org; Wed, 21 Jan 2004 07:39:16 -0500 Original-Received: from localhost.localdomain.byrd.xs4all.nl (byrd [127.0.0.1]) by localhost.localdomain (8.12.10/8.12.10) with ESMTP id i0LCegs7002589; Wed, 21 Jan 2004 13:40:42 +0100 Original-To: Viktor Pavlenko In-Reply-To: <16397.63705.338864.586672@shmyh.ua> X-Mailer: VM 7.14 under Emacs 21.3.1 X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.1.2 Precedence: list List-Id: General Guile related discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-user-bounces+guile-user=m.gmane.org@gnu.org Xref: main.gmane.org gmane.lisp.guile.user:2675 X-Report-Spam: http://spam.gmane.org/gmane.lisp.guile.user:2675 vvp@rogers.com writes: > > (let* ((var1 (+ (something) 2)) > (var2 (+ (something var1) var1)) > (var3 (something var1 var2))) > > If you need to change var3 at a later point, just give it another name: > > (let ((var3-2 (+ (something-else var3)))) > (... > > instead of set!-ting it. The problem with set! in a lexically scoped > language is that you can change the binding of a variable defined at a > higher level by mistake: I know about all this. The example was a little contrived. The things I have in mind are statements which currently return SCM_UNSPECIFIED. I think it looks stupid to do (let* ((a (something)) (unused (display a)) (b (something-else a)) .. ) which introduces a variable unused, and puts emphasis on the declaration, not on the main action of the statements. -- Han-Wen Nienhuys | hanwen@xs4all.nl | http://www.xs4all.nl/~hanwen _______________________________________________ Guile-user mailing list Guile-user@gnu.org http://mail.gnu.org/mailman/listinfo/guile-user