[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: master 42950e9: Fix a few Edebug specifications where code is wrappe
From: |
Philipp |
Subject: |
Re: master 42950e9: Fix a few Edebug specifications where code is wrapped in lambdas. |
Date: |
Sun, 23 May 2021 12:22:00 +0200 |
> Am 22.05.2021 um 19:31 schrieb Stefan Monnier <monnier@iro.umontreal.ca>:
>
>> Fix a few Edebug specifications where code is wrapped in lambdas.
>>
>> As the Info node `(elisp) Specification List' explains, it is not
>> correct to use `body' or t for a piece of code that the macro wraps in
>> a `lambda' form. These should use `def-body' instead.
>
> There is a slight misunderstanding here: if the end behavior is the same
> as what could happen without a lambda, then there's no need to use
> `def-body`.
>
> The use `def-body` is only needed if it's possible to enter this code
> from non-instrumented code (e.g. when the lambda is passed to
> `run-with-timer`).
>
> In the case of `displaying-byte-compile-warnings`, for example, there is
> no need for `def-body`.
Could you please clarify the manual then? Right now it says:
If your
macro wraps the expression with ‘lambda’ before it is evaluated,
use ‘def-form’ instead.