emacs-devel
[Top][All Lists]
Advanced

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

Re: implementing a reader macro


From: Stefan Monnier
Subject: Re: implementing a reader macro
Date: Fri, 22 Jul 2022 16:32:01 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

> How difficult is it to implement a new reader macro for Elisp?
> The one I particularly wish to be ported from Clojure is the "discard
> macro" - `#_`. What it does is that it ignores the next form completely.

Does `clojure-mode` support that correctly?
Scheme has a similar construct and I found it difficult to make
`scheme-mode` handle it correctly (so: it doesn't).

I don't think we want to add to ELisp a feature that our support tools
can't handle well.

> It is a very nice way of (usually temporarily) commenting out sexps
> without disrupting the structure too much. Of course, we can employ nice
> tricks such as one described by Malabarba:
> http://endlessparentheses.com/a-comment-or-uncomment-sexp-command.html
> But wouldn't it be nice to have something even better?

I don't think this feature pays for itself, personally.
There are plenty of alternative solutions that don't require changing
the syntax of the language.


        Stefan




reply via email to

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