bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#66410: 28.2; Symbol’s function definition is void: command-query


From: Stefan Kangas
Subject: bug#66410: 28.2; Symbol’s function definition is void: command-query
Date: Sun, 8 Oct 2023 20:17:39 +0000

Stephen Berman <stephen.berman@gmx.net> writes:

> (defun command-query (command query &optional verbose)
>   "Make executing COMMAND issue QUERY to the user.
> This will, by default, use `y-or-n-p', but if VERBOSE,
> `yes-or-no-p' is used instead."
>   (put command 'disabled
>        (list 'query (not (not verbose)) query)))
>
> so you could add it to your init file before the above use of it.  (But
> if you later update to Emacs 29.1 or later, you should then remove the
> definition from your init file.)

I'd use this:

(when (< emacs-major-version 29)
  (defun command-query (command query &optional verbose)
    "Make executing COMMAND issue QUERY to the user.
This will, by default, use `y-or-n-p', but if VERBOSE,
`yes-or-no-p' is used instead."
    (put command 'disabled
         (list 'query (not (not verbose)) query))))

I don't see a bug here, so I'm closing this now.  Thanks.





reply via email to

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