Subject: bug#61281: “`(a \, b)” equals to “`(a . , b)”

From: Drew Adams <[email-masked]>
Date: Mon, 6 Feb 2023 16:43:32 +0000

> > S-exps are defined recursively.  ",X" is read syntax of a valid s-exp,
> > and I don't think we want to make the reader raise an error for it.
> 
> FWIW, clisp generates an error if the comma occurs outside of backquote.
> If you quote the comma, it is treated as an ordinary symbol character.
> 
> $ clisp -q -x ',X'
> *** - READ: comma is illegal outside of backquote
> $ clisp -q -x '\,X'
> *** - SYSTEM::READ-EVAL-PRINT: variable |,X| has no value
> 
> $ clisp -q -x '`\,X'
> |,X|

Thanks for that info, confirming what clisp does.
Those are all what I'd expect/hope: the \,x
inside the backquote sexp is read as the symbol
|,x|.

The Elisp question (bug) is really only about a
_bare_ escaped comma, not one that's immediately
followed by symbol chars (e.g. x).

E.g., what do these give?

$ clisp -q -x '`\,'
$ clisp -q -x '`(\, x)'