emacs-devel
[Top][All Lists]
Advanced

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

Re: How to warn about obsolete file in ELPA package


From: Stefan Monnier
Subject: Re: How to warn about obsolete file in ELPA package
Date: Sat, 06 Feb 2021 22:54:54 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

>>> We would like to emit an obsoletion warning when dash-functional.el is
>>> used, similar to the one for lisp/obsolete/* libraries.
>> I think you can get exactly this behavior by placing the file in
>> a directory called `obsolete`.
> Could we add something like (cl-declaim obsolete) to make this independent of 
> the filename?

You can probably cook something up using `macroexp--warn-and-return`.
E.g. something like:

    (defmacro my-\, (exp) (eval exp t))
    (my-\,
     (when (fboundp 'macroexp--warn-and-return) ;; New in Emacs-24.3
       (macroexp--warn-and-return
        "dash-functions is obsolete, just require dash instead" nil)))


-- Stefan




reply via email to

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