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

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

bug#45607: 27.1; compiled replace-string breaks repeat-complex-command


From: Juri Linkov
Subject: bug#45607: 27.1; compiled replace-string breaks repeat-complex-command
Date: Sat, 13 Aug 2022 22:30:50 +0300
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu)

>> OTOH, `duplicate-dwim' is optimized to call `use-region-p' only once:
>>
>>   (cond
>>    ((use-region-p)
>>     (let* ((beg (region-beginning))
>>            (end (region-end))
>
> I don't think that makes much difference when it comes to interactive
> specs:
>
> (benchmark-run 1000000 (use-region-p))
> => (0.038645288 0 0.0)
>
> If you're calling `duplicate-dwim' interactively more than a million
> times a second, you'll get a slowdown of a couple hundredths of a
> second.

But still `use-region-p' is used to start a new logical branch of `cond'.





reply via email to

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