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

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

bug#3418: Issue with compile.el and compilation-parse-errors-filename-fu


From: npostavs
Subject: bug#3418: Issue with compile.el and compilation-parse-errors-filename-function
Date: Sat, 12 Aug 2017 11:42:05 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2.50 (gnu/linux)

Eli Zaretskii <eliz@gnu.org> writes:

>> We could do something like
>> 
>>     (condition-case err
>>         (funcall compilation-parse-errors-filename-function filename 
>> spec-dir)
>>       (wrong-number-of-arguments
>>        ;; Try again with single arg for backwards compatibility.
>>        (funcall compilation-parse-errors-filename-function filename)))
>
> Or use func-arity?

I think func-arity could fail in case the function is advised or created
with `apply-partially'.  On the other hand the condition-case trick can
cause problems if there is an unrelated wrong arguments error inside the
function (perhaps this can be migitated by checking the error
information).  Doesn't really matter too much either way I guess, it's
all minor corner cases.






reply via email to

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