Dmitry Gutov <dgutov@yandex.ru> writes:
I'm not a big fan of the 'interactive' argument. It could be replaced
by using (called-interactively-p 'interactive), though I'm not sure
how idiomatic that is.
Not necessarily a fan either, but my takeaway from recent discussions on
emacs-devel is that the argument is preferred to called-interactively-p,
which should only be used when a function's arglist is set in stone.
<E1k7A3J-0005gG-4K@fencepost.gnu.org>
https://lists.gnu.org/archive/html/emacs-devel/2020-08/msg00463.html
<jwvzh6ubtbe.fsf-monnier+emacs@gnu.org>
https://lists.gnu.org/archive/html/emacs-devel/2020-08/msg00472.html
I see a few dozen hits for "&optional \([\w-]+ \)*interactive)" under
lisp/, so it seems to be an established practice.
PS: I've just seen Juri's reponse in bug#45765#26; I'm glad there is a
consensus on the first patch, because after looking at more in-tree
examples of optional INTERACTIVE arguments, I found myself agonizing
over spelling the spec (list nil nil t), '(nil nil t), or "i\ni\np".