[Top][All Lists]

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

Re: Why looking-at-p works?

From: Emanuel Berg
Subject: Re: Why looking-at-p works?
Date: Tue, 06 Mar 2018 09:49:59 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4 (gnu/linux)

Marcin Borkowski wrote:

> (defsubst looking-at-p (regexp) "\ Same as
> `looking-at' except this function does not
> change the match data." (let
> ((inhibit-changing-match-data t)) (looking-at
> regexp)))
> What happens is that if I make looking-at in
> the above code fail (e.g., by saying
> (looking-at-p 123)),
> inhibit-changing-match-data remains nil, even
> though there is no unwind-protect here.
> Why does it work like this?

Do you need dynamic scope for `let' to work
like that?

underground experts united

reply via email to

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