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

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

bug#51094: Check if run-with{-idle, }-timer needs to create a timer


From: Philip Kaludercic
Subject: bug#51094: Check if run-with{-idle, }-timer needs to create a timer
Date: Fri, 08 Oct 2021 11:33:27 +0000

Lars Ingebrigtsen <larsi@gnus.org> writes:

> Lars Ingebrigtsen <larsi@gnus.org> writes:
>
>> Yes, the semantics of running things from a timer are different from
>> running them in the normal flow, so we can't transform 0-delay timers
>> into funcalls.
>
> See for instance:
>
>   (when (> (minibuffer-depth) 0)
>     ;; We're inside a minibuffer already, so if the emacs-client is trying
>     ;; to open a frame on a new display, we might end up with an unusable
>     ;; frame because input from that display will be blocked (until exiting
>     ;; the minibuffer).  Better exit this minibuffer right away.
>     (run-with-timer 0 nil (lambda () (server-execute-continuation proc)))
>
> So this change is a no go.

Ok, that makes sense.

One last question, would it make sense to provide a function like
run-with-timer that would work like my patch?

-- 
        Philip Kaludercic





reply via email to

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