[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-users] need idea for read-syntax

From: felix
Subject: Re: [Chicken-users] need idea for read-syntax
Date: Wed, 19 Nov 2003 19:29:10 +0100
User-agent: Opera7.11/Linux M2 build 406

On Tue, 18 Nov 2003 10:53:22 +0000, Category 5 <address@hidden> wrote:

felix wrote:

Ok, shall it be #{ ... }#, then?

Hmmn.  This isn't too bad for the statement-sequence case, where the {}
even suggest the block structure of a C function, but I don't think it
fits the typed-value case well at all (partly for the same reason).

I can see Peter's point, but I think the use cases of #[ ]# are
different enough from literal vector notation to avoid confusion.  (Then
again, I don't have any code that writes vectors as #[1 2 3].  =)

Personally, I don't care much wether it's #{ ... }# or #[ ... ]#.
The problem with the former is that it would some changes to the compiler
(which uses it extensibly for another hackish purpose), and that would
cause a bootstrapping problem (not serious, though). The problem with the
latter is that the association with embedded C code seems a bit far- fetched. Another option would of course be to drop it entirely and use `foreign- code'.

Actually I'd rather see the conflation of []/() disappear and have plain
[] used to represent vectors in Scheme, making them look less like
second-class citizens.  But that's a whole 'nother discussion.

Absolutely. I use [] quite a lot as a replacement for normal parens,
especially when nesting gets deep:

(let-values ([(x y z) ...])

appears to be more readable (for me) than

(let-values (((x y z) ...))


reply via email to

[Prev in Thread] Current Thread [Next in Thread]