FYI...
The Common Lisp implementation of all the "readable" notation tiers seems to be
working well.
One oddness is that clisp (a widely-used Common Lisp implementation) forces all
the symbols to be displayed with |...| around them when using neoteric- or
sweet-expressions. I've tracked this down to an oddity of its implementation
of "write", which varies its display depending on the readtable. I don't see
an easy way to change this in the short term, and it works as-is, so in the
short term I'll just document this as an oddity in the tutorial.
In the long term, this could be fixed through a small patch to clisp. I've
already posted a feeler Qon the clisp mailing list, to see if the clisp folks
would be willing to entertain a patch. Below is part of that message, for your
information.
--- David A. Wheeler
=======================================================
Okay, I've looked through the clisp code and I found the problem.
The issue is in file "src/io.d" function "pr_symbol_part"
(which starts line 7004 on 2013-05-06), with this code.
It forces |...| around symbols based on what happens to be in the current
readtable:
======================================================
var object syntax_table; /* syntaxcode-table, with char_code_limit elements */
var uintW rtcase; /* readtable-case */
{
var object readtable;
get_readtable(readtable = ); /* current Readtable */
syntax_table = TheReadtable(readtable)->readtable_syntax_table;
rtcase = RTCase(readtable);
}
/* traverse string: */
SstringDispatch(string,X, {
...
if (!(syntax_table_get(syntax_table,c) == syntax_constituent))
goto surround; /* no -> must use |...| */
======================================================
Would the clisp folks be willing to entertain a tweak so that
users could better control this auto-escaping, if they desire?
For example, perhaps there could be a *pr-symbol-readtable* variable that
defaults
to nil. Then, in the code above, use the readtable referenced in
*pr-symbol-readtable*
if it's non-nil, and if it's nil (the default), use the current readtable.
That would maintain the current behavior by default, but be more flexible.
--- David A. Wheeler
------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and
their applications. This 200-page book is written by three acclaimed
leaders in the field. The early access version is available now.
Download your free book today! http://p.sf.net/sfu/neotech_d2d_may
_______________________________________________
Readable-discuss mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/readable-discuss