[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Emacs-diffs] master 55cdebc: Make Tramp compatible to recent progre
From: |
Stefan Monnier |
Subject: |
Re: [Emacs-diffs] master 55cdebc: Make Tramp compatible to recent progress-reporter-update |
Date: |
Sat, 15 Jun 2019 12:28:48 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) |
>>> + (if (equal (tramp-compat-funcall 'func-arity #'progress-reporter-update)
>>> + '(1 . 3))
>> This gives the wrong result if progress-reporter-update is advised
>> (e.g. for `debug-on-entry`, or `trace-function`, or ...)
> Do you know a better test?
None is perfect. Other than looking at the Emacs version number, you
can also do
(condition-case (progress-reporter-update ...)
(wrong-number-of-arguments (progress-reporter-update ...)))
I find this latter one less troublesome in practice than testing arity,
Stefan