[Top][All Lists]

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

Re: [Chicken-users] module and macro documentation

From: felix winkelmann
Subject: Re: [Chicken-users] module and macro documentation
Date: Sat, 24 May 2008 15:55:37 +0200

On Fri, May 23, 2008 at 8:53 PM, Peter Bex <address@hidden> wrote:
> Thanks for writing this up! It's a very clear document in most points,
> especially the examples on explicit renaming are excellent. The
> documentation on 'syntax' could use some example code, the current
> description is a little terse.

Quite true. "Syntax" is actually sort of weird: it is used in the
implementation of "syntax-rules", and really does nearly
the same as "quote", but does not strip syntactical context
information from any identifiers appearing in the literal.
You normally should not need this.

> Small aside: There's now wiki syntax for procedure and syntax
> definitions at
> Using this will make the wiki more easily scannable by automatic
> tools in the future. At least, we hope it will :)

Ok, I'll try to make more use if it.

>> Feedback is welcome. I'm not sure on the module syntax, but found
>> this one (taken from psyntax) to be relatively natural and simple.
> Yeah, I mostly agree. It is slightly annoying that all code inside the
> module always ends up indented with such a system, though.  (minor
> advantage: it allows you to let one file define more than one module)

It also simplifies context management. Any other structuring mechanism
must be file-based, which is sometimes too course grained or forces
you to split everything into little files. But it's in the end just a matter
of taste.

>> Different naming and syntax are still possible, of course.
> I always liked the external definitions from the old scheme 48 system,
> but they're not as simple.

It shouldn't be too hard to create a wrapper macro for this.
The separation of interface and structure would require compile-time
registration of interfaces, but that's not hard. I'll write that at some
stage (much simpler, no config language, etc.).


reply via email to

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