[gambit-list] Character encoding and the repl

Mikael More mikael.more at gmail.com
Sun May 31 07:00:50 EDT 2015


The new autodetection routine at lib/_io#.scm:747+ in
is super nice.

I agree it's nice that all readable european, asian, etc. characters come
out unescaped, but it's weird to know that Gambit would come
not-copy-paste-proof out of the box, and that you need a specialized script
at startup to fix that.

I use the best terminal software and it does not show all unicode

To understand the implications of unescaped Unicode characters, I read up
on http://unicode.org/charts/ and other places, and it seems that the worst
abuse of Unicode characters is illustrated here
http://www.marlborotech.com/Zalgo.html , and maybe also the
right-to-left/left-to-right characters can cause disorder - it's quite bad
but not fatal.

I would primarily suggest that a command line option would be added that
configures the escaping e.g. -:E  , -:E127 (or maybe -:T127 for terminal
and -:F127 for files).

Secondarily I would suggest reverting lib/_io.scm:13119 back
to (##integer->char 127) i.e. escape all >127 again, as at least I find
this to be really more a "safe by default" behavior.

Anyone else has any thoughts on this topic?

2015-05-31 1:11 GMT+05:30 Marc Feeley <feeley at iro.umontreal.ca>:

> > On May 30, 2015, at 3:26 PM, Adam <adam.mlmb at gmail.com> wrote:
> >
> > Marc, what do those who want preserve the escaping of >=128 do
> (independent of which terminal encoding is used but for instance with -:t8)?
> >
>   (output-port-readtable-set!
>     (repl-output-port)
>     (readtable-max-unescaped-char-set
>       (output-port-readtable (repl-output-port))
>       (integer->char 127)))
> In your Scheme program or gambcini file.
> Marc
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.iro.umontreal.ca/pipermail/gambit-list/attachments/20150531/d82a3359/attachment.htm>

More information about the Gambit-list mailing list