From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: =?UTF-8?B?Sm/Do28gVMOhdm9yYQ==?= Newsgroups: gmane.emacs.devel Subject: Re: run-with-timer vs run-with-idle-timer Date: Wed, 9 May 2018 20:34:59 +0100 Message-ID: References: <87tvrgd972.fsf@gmail.com> <83a7t8puaw.fsf@gnu.org> <87efikd65q.fsf@gmail.com> <838t8spsd5.fsf@gnu.org> <87tvrgbpys.fsf@gmail.com> <837eocprcw.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="001a1149b0a0d6bf0b056bcb0087" X-Trace: blaine.gmane.org 1525894405 28260 195.159.176.226 (9 May 2018 19:33:25 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Wed, 9 May 2018 19:33:25 +0000 (UTC) Cc: emacs-devel To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed May 09 21:33:20 2018 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fGUpz-0007F2-JY for ged-emacs-devel@m.gmane.org; Wed, 09 May 2018 21:33:19 +0200 Original-Received: from localhost ([::1]:58672 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fGUs6-0005I7-I6 for ged-emacs-devel@m.gmane.org; Wed, 09 May 2018 15:35:30 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:52112) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fGUrz-0005Dx-QL for emacs-devel@gnu.org; Wed, 09 May 2018 15:35:24 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fGUry-0001Je-Np for emacs-devel@gnu.org; Wed, 09 May 2018 15:35:23 -0400 Original-Received: from mail-qk0-x233.google.com ([2607:f8b0:400d:c09::233]:38345) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fGUrw-0001Ip-Vc; Wed, 09 May 2018 15:35:21 -0400 Original-Received: by mail-qk0-x233.google.com with SMTP id b39so28476177qkb.5; Wed, 09 May 2018 12:35:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=iux93F/AyramnaqJ+JF55tHRky9/zJqZ0fIwdyhiZQM=; b=GIcUAuRcgoikzOzWY1KO70Ipl2DxlhowrC20TRgKP8A5CxGhN3Xt8AtnC+xsIR69Le UqC6gS9G4RJdLyQZPRfuNhKGdiqTvYtcHiG+v6vuY61q9yp7htpGPMnyZnuWU0i+XbHQ YLGG3gR5J3sCOatueGYekqTIoRYSjgjWuVXXBn39NQoSIv9BnXi6XC6+SYDSF4n91GcH dB2Ym3hA+21Doze5WBEHHy5fcjI93JO9OB3gJBDZBw79LI8wRYLUkO2A4LO1p3CTI2Ry Z4MYEfSDnyNIcyNlE/39vDMurJ2wUQhSVL5Q0KabSBepAJVFhrjaCdfJfhYyV1klKXVM C2qw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=iux93F/AyramnaqJ+JF55tHRky9/zJqZ0fIwdyhiZQM=; b=iekQQkXEgeTkvxlwfDWiplk+wDO19smvxNKncpFvxEPcTgiWxt+xwuah1UghwHnI/2 pNVtuEhYZOPHb3nJBmB0Y74fuvLSMBvyULI9OmYNRssJHxc0NPlHwyHD/ChK+ooGS7vO JW4tJ9X5vY1WA9AxZHWFyMQNCfAV0Tda/TX/B4xADFHFzHmWdFSz3YTYkKZ4avniPyRl +otRY5Zq+Ote8eW9juHUy9kawqFmmXAnoB61ULG8OmqKS2T99WGJXutAGmZLuoaR9qpI XWo00AsuV2goJFpowwsRMV87DkpmRsXNd5qnmfQaTkEzZ51MYC0TkuSaPkOkmR7ETUfd wu7A== X-Gm-Message-State: ALQs6tBB1twCudVVr32wrm4t/PRqIU7Pqw9Zz7+u7cbVEpXDgCCS1fEe k+xodk12kp43s6MJrBTGuzkSv6JgK5gDGoAelvVX6g== X-Google-Smtp-Source: AB8JxZoGxheeuuDXqNDUeIkEKYLF4oWL/GRjTPczeHpdbj57Pjzj33ir3w9TKPHiVwDrH/V/5H25d4wHw+jNpWXksek= X-Received: by 10.55.204.5 with SMTP id r5mr38123999qki.169.1525894520158; Wed, 09 May 2018 12:35:20 -0700 (PDT) Original-Received: by 10.12.148.200 with HTTP; Wed, 9 May 2018 12:34:59 -0700 (PDT) In-Reply-To: <837eocprcw.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:400d:c09::233 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:225176 Archived-At: --001a1149b0a0d6bf0b056bcb0087 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Wed, May 9, 2018 at 8:21 PM, Eli Zaretskii wrote: > > From: Jo=C3=A3o T=C3=A1vora > > Cc: emacs-devel@gnu.org > > Date: Wed, 09 May 2018 20:15:23 +0100 > > > > > An idle timer set for 600 seconds will run when ten minutes have > > > elapsed since the last user command was finished, even if subprocess > > > output has been accepted thousands of times within those ten minutes, > > > and even if there have been garbage collections and autosaves. > > > > Doesn't this contradict what you told me first? I.e doesn't this > > contradict the fact that this never returns? > > > > (catch 'done > > (run-with-idle-timer 600 nil (lambda () (throw 'done nil))) > > (while t (accept-process-output nil 0.1))) ; 6 thousand times > > > > or should the manual be saying "even if subprocesses output has been > > non-explictly accepted thousands of times"? > > "Subprocess output" in that text doesn't include what > accept-process-output delivers, the text alludes to reading of > subprocess output via filter functions. > Hmm... There certainly seems to be more than a little room for confusion, but I couldn't probably think of a better phrasing. Thanks, and hoping future confused users can find this thread. Jo=C3=A3o --001a1149b0a0d6bf0b056bcb0087 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
On W= ed, May 9, 2018 at 8:21 PM, Eli Zaretskii <eliz@gnu.org> wrote:
> From: Jo=C3=A3o T=C3= =A1vora <joaotavora@gmail.com>
> Cc:
emacs-devel@gnu.org
> Date: Wed, 09 May 2018 20:15:23 +0100
>
> > An idle timer set for 600 seconds will run when ten minutes have<= br> > > elapsed since the last user command was finished, even if subproc= ess
> > output has been accepted thousands of times within those ten minu= tes,
> > and even if there have been garbage collections and autosaves. >
> Doesn't this contradict what you told me first?=C2=A0 I.e doesn= 9;t this
> contradict the fact that this never returns?
>
>=C2=A0 =C2=A0(catch 'done
>=C2=A0 =C2=A0 =C2=A0(run-with-idle-timer 600 nil (lambda () (throw '= ;done nil)))
>=C2=A0 =C2=A0 =C2=A0(while t (accept-process-output nil 0.1))) ; 6 thou= sand times
>
> or should the manual be saying "even if subprocesses output has b= een
> non-explictly accepted thousands of times"?

"Subprocess output" in that text doesn't include what<= br> accept-process-output delivers, the text alludes to reading of
subprocess output via filter functions.

Hmm... There certainly seems to be more than a little room for=C2=A0
=
confusion, but I couldn't probably think of a better phrasing. Tha= nks,=C2=A0
and hoping future confused users can find this thread.=

Jo=C3=A3o
--001a1149b0a0d6bf0b056bcb0087--