guile-reader-devel
[Top][All Lists]
Advanced

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

[guile-reader-devel] Guile-Bash reader extensions


From: Ludovic Courtès
Subject: [guile-reader-devel] Guile-Bash reader extensions
Date: Fri, 05 Jun 2015 14:18:37 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)

Dmitry Bogatov <address@hidden> skribis:

> My use-case is Guile interface to Bash, and I would like to get `$foo'
> be read as (variable-ref 'foo) but just `foo' as symbol.

Sorry to spoil the party ;-), but I think you should avoid that.

The problem with reader extensions is that they do not compose well.  If
a program uses guile-bash, or if a module is loaded from guile-bash,
then suddenly it gets the reader extension, and that extension could
break it, for instance because it uses $ identifiers (this is not
uncommon; one example is (system base lalr).)

So I think you should keep ‘variable-ref’ as is (perhaps with a
different name though, to avoid confusion with Guile’s ‘variable-ref’.)

If you have concrete use cases in mind where you think repetition would
be a serious drawback, then we can discuss it.

Thanks,
Ludo’.



reply via email to

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