Hi, Kevin Ryde <[EMAIL PROTECTED]> writes:
> I have doubts. Can you give more examples of when it might be used? > Elisp syntax is probably not a good example, since elisp code wouldn't > start with "define-module". There are really two questions in your message. One is "do we really need syntax configuration beyond #,() and the likes?". The second one is "why would we write Guile modules that use a potentially significantly different syntax?" The per-module mechanisms is addressing the latter. My answer to the former is "yes" and `guile-reader' is trying to address this. The point is the following: one may wish to write a Guile module using her own syntax variant (no matter which one), yet want it to be well integrated into Guile's module hierarchy, correctly read, and not have unexpected side effects on the user's code. IMO, per-module readers are a way to fix the current scheme were there's only one instance of `read' and any module can happily modify it via `read-enable' and the likes. Ultimately, I'd be very glad if `read-enable', for instance, could translate into something like (%read-enable (module-reader (current-module)) something) In the end, `define-module' could almost be thought of as the Guile equivalent to the `#!' sequence found at the beginning of Unix scripts. As for syntax variants, my main interest currently is the syntax of Skribe[1] which borrows from Scheme, DSSSL, and also has special forms using square brackets. But again, that is a question relevant to `guile-reader' more than to the per-module reader mechanism. Thanks, Ludovic. [1] http://www-sop.inria.fr/mimosa/fp/Skribe/ _______________________________________________ Guile-devel mailing list Guile-devel@gnu.org http://lists.gnu.org/mailman/listinfo/guile-devel