emacs-devel
[Top][All Lists]
Advanced

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

Re: Dealing with obsoletion warnings in non-core code


From: Eli Zaretskii
Subject: Re: Dealing with obsoletion warnings in non-core code
Date: Mon, 28 Sep 2020 21:16:09 +0300

> From: Stefan Monnier <monnier@iro.umontreal.ca>
> Date: Mon, 28 Sep 2020 13:32:47 -0400
> 
> > Ideally I'd like to be able to write the following instead to avoid the
> > needless repetition:
> >
> >     (if (fboundp 'recommended-function)
> >         (recommended-function)
> >       (old-but-useful-function))
> 
> Indeed, it's a problem of which I'm aware but I don't know how to solve
> it nicely.

What about something like the below?

  (if (> emacs-major-version NN)
    (defun recommended-function (...)
      ...))



reply via email to

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