From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?UTF-8?Q?Jo=C3=A3o_?= =?UTF-8?Q?T=C3=A1vora?= Newsgroups: gmane.emacs.bugs Subject: bug#41531: 27.0.91; Better handle asynchronous eldoc backends Date: Sat, 4 Jul 2020 10:21:43 +0100 Message-ID: References: <875zckuet9.fsf@gmail.com> <87sgecssch.fsf@gmail.com> <83k0zjvi4c.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="000000000000ea6e9b05a99a2bab" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="21771"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 41531@debbugs.gnu.org, Stefan Monnier , andreyk.mad@gmail.com, dgutov@yandex.ru To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Jul 04 11:22:10 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jreN7-0005XJ-Ig for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 04 Jul 2020 11:22:09 +0200 Original-Received: from localhost ([::1]:53332 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jreN6-0007nL-HQ for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 04 Jul 2020 05:22:08 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:34158) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jreN0-0007nA-1H for bug-gnu-emacs@gnu.org; Sat, 04 Jul 2020 05:22:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:46505) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jreMz-0003GF-P7 for bug-gnu-emacs@gnu.org; Sat, 04 Jul 2020 05:22:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jreMz-0003DL-Kd for bug-gnu-emacs@gnu.org; Sat, 04 Jul 2020 05:22:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: =?UTF-8?Q?Jo=C3=A3o_?= =?UTF-8?Q?T=C3=A1vora?= Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 04 Jul 2020 09:22:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 41531 X-GNU-PR-Package: emacs Original-Received: via spool by 41531-submit@debbugs.gnu.org id=B41531.159385451912348 (code B ref 41531); Sat, 04 Jul 2020 09:22:01 +0000 Original-Received: (at 41531) by debbugs.gnu.org; 4 Jul 2020 09:21:59 +0000 Original-Received: from localhost ([127.0.0.1]:58051 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jreMx-0003D4-BY for submit@debbugs.gnu.org; Sat, 04 Jul 2020 05:21:59 -0400 Original-Received: from mail-io1-f50.google.com ([209.85.166.50]:38071) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jreMv-0003Cs-4w for 41531@debbugs.gnu.org; Sat, 04 Jul 2020 05:21:57 -0400 Original-Received: by mail-io1-f50.google.com with SMTP id f6so19041948ioj.5 for <41531@debbugs.gnu.org>; Sat, 04 Jul 2020 02:21:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=B8tYZnjh4Ij0tuHzim3NUUigGwD8Yj54B/Cp6F7Zlfg=; b=GyFiVIULbm72Q1DjuI52B1FKT/hERS2h+AYg+2meFTX6g8MyfWgnuTURZyBzw9e1Tj fGFGUfdNsgUpeHX6awYZxRZBsWrZkBsKO1b5KmXVzC1W0Op9UcjottSSrctTP7kcVpIq 6qLe1Bv1LkL0AJiaRMbugeNyQFseY6sME6rFGltWUu9py6Cly/oWHawvnV2hKYs85nP4 6SItKrxlVAzYhm5pBsCSJc9itE82h6z//WzC3HkwXJ8vAdRYHZ8VmK1+Qf69kdFnzb8E w2BKVLjq2P06Hpz7DrZ+7mAnAzhrhShw+cwPA/Cz+34nR8BUKE+BEdsMw931QSfT9tGS EU/Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=B8tYZnjh4Ij0tuHzim3NUUigGwD8Yj54B/Cp6F7Zlfg=; b=UwTuG8ht7DCel4QTp/vUOIqSOWCAy/2QtCCtTH1gNsmaf8sMmcEJrGG6VqpINj/0cK Yu0qobCKn2u16a27o2/DmLBWvO48exL6mK0En9VBPcuhDfHs6/pKs83ywlsR9Hto+UFB g4xtl4AWhJRwaS+q/ahljun4umzmgdU8+UlvNHkSrGewXT7SWrAmK6IGsEZkEsSX7ori ND4DIeWLcf9DGcOOQIg/7BnSfv3RwNCT1UKMB4tkCtGLJhGNJZ4EWywPMhVIGzlaMKIm JcHFj0CbzX4yBDnCj+DqmOwuB8miMyNJ+O59O25F1ah1K9HE529gmymLEOAkakMSRD4U PcwA== X-Gm-Message-State: AOAM531pif/rBVFtZTC/AJZuF0l6xXMkFd3QMBe9YZ4cRwVkxtaHsGIc cWGQSQKZmraRHlbbIai+Ss7PZFvSR/99RV/+bMA= X-Google-Smtp-Source: ABdhPJy1HD0q4aGulmElEXSnhPaFHvzBP5ErCHx9Rkj9zsdo48Gbtm1FHsgQq7NZsZ81K4sijURAhnFSIPIVi9snM7Y= X-Received: by 2002:a02:9642:: with SMTP id c60mr42634940jai.71.1593854510393; Sat, 04 Jul 2020 02:21:50 -0700 (PDT) In-Reply-To: <83k0zjvi4c.fsf@gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:182683 Archived-At: --000000000000ea6e9b05a99a2bab Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Thanks for the feedback, Eli. I'll get to each point later on. But I'm surprised the NEWS entry I had written got lost. In the git rebasing, maybe. Jo=C3=A3o On Sat, Jul 4, 2020, 08:45 Eli Zaretskii wrote: > > From: Jo=C3=A3o T=C3=A1vora > > Date: Tue, 30 Jun 2020 12:31:10 +0100 > > Cc: Stefan Monnier , andreyk.mad@gmail.com, > > Dmitry Gutov > > > > The work that started with this discussion is now mostly complete. It > > has been sitting in the scratch/eldoc-async branch of the Savannah repo > > for a while, but I've been very busy and didn't have time to annouce it= . > > Thanks. > > > Anyway I think my efforts are ready to push to master. I'll do so soon > > unless someone raises a serious problem about it. > > Not a serious problem, but some comments: > > > -(defun eldoc-message (&optional string) > > +(make-obsolete > > + 'eldoc-message "use `eldoc-documentation-functions' instead." "1.1.0"= ) > > Isn't the version part of the obsolete message supposed to tell the > version of Emacs? > > The change to the number of arguments of the functions in the > eldoc-documentation-functions hook is backward-incompatible, isn't it? > I see you've changed the relevant functions in our sources, but what > about 3rd-party packages? > > Also, the doc string of this hook needs clarification regarding the > arguments: it first says that CALLBACK is the only mandatory argument > to the hook functions, but then, out of the blue, appear additional > arguments DOCSTRING and a list of key-value pairs. Confusing. > > The doc strings have some words in UK English spelling "(e.g., > "honour"), please fix that. Also, please make sure comments all start > with a capital letter, end with a period, and comprise full English > sentences. > > The doc string of eldoc-documentation-compose doesn't say a word about > the function's argument. > > In the doc string of eldoc-documentation-strategy, you use the phrase > "queries the special hook for all functions that produce doc strings" > to mean, AFAIU, that the specified functions in the hook-variable list > are called. IMO, this wording could be confusing; suggest to use this > instead: > > `eldoc-documentation-compose': calls all the functions in the hook, > and displays all of the resulting doc strings ... > > This doc string doesn't explain the use of the timer, it explains the > reason for its existence. It should also describe the use: > > > +(defvar eldoc--enthusiasm-curbing-timer nil > > + "Timer used by `eldoc-documentation-enthusiast' to avoid blinking.") > > Last, but not least: the "async" part of the branch's name hints on > some advanced and extremely useful functionality that these changes > are supposed to allow, but I see no mention of that in NEWS and in the > manual bits. What did I miss? > --000000000000ea6e9b05a99a2bab Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Thanks for the feedback, Eli.

=
I'll get to each point later on. But I'm surprise= d the NEWS entry I had written got lost. In the git rebasing, maybe.
<= div dir=3D"auto">
Jo=C3=A3o

On Sat, Jul 4, = 2020, 08:45 Eli Zaretskii <eliz@gnu.org<= /a>> wrote:
> From: Jo=C3=A3o= T=C3=A1vora <joaotavora@gmail.com>
> Date: Tue, 30 Jun 2020 12:31:10 +0100
> Cc: Stefan Monnier <monnier@iro.umontreal.ca>, andr= eyk.mad@gmail.com,
>=C2=A0 Dmitry Gutov <dgutov@yandex.ru>
>
> The work that started with this discussion is now mostly complete.=C2= =A0 It
> has been sitting in the scratch/eldoc-async branch of the Savannah rep= o
> for a while, but I've been very busy and didn't have time to a= nnouce it.

Thanks.

> Anyway I think my efforts are ready to push to master.=C2=A0 I'll = do so soon
> unless someone raises a serious problem about it.

Not a serious problem, but some comments:

> -(defun eldoc-message (&optional string)
> +(make-obsolete
> + 'eldoc-message "use `eldoc-documentation-functions' ins= tead." "1.1.0")

Isn't the version part of the obsolete message supposed to tell the
version of Emacs?

The change to the number of arguments of the functions in the
eldoc-documentation-functions hook is backward-incompatible, isn't it?<= br> I see you've changed the relevant functions in our sources, but what about 3rd-party packages?

Also, the doc string of this hook needs clarification regarding the
arguments: it first says that CALLBACK is the only mandatory argument
to the hook functions, but then, out of the blue, appear additional
arguments DOCSTRING and a list of key-value pairs.=C2=A0 Confusing.

The doc strings have some words in UK English spelling "(e.g.,
"honour"), please fix that.=C2=A0 Also, please make sure comments= all start
with a capital letter, end with a period, and comprise full English
sentences.

The doc string of eldoc-documentation-compose doesn't say a word about<= br> the function's argument.

In the doc string of eldoc-documentation-strategy, you use the phrase
"queries the special hook for all functions that produce doc strings&q= uot;
to mean, AFAIU, that the specified functions in the hook-variable list
are called.=C2=A0 IMO, this wording could be confusing; suggest to use this=
instead:

=C2=A0 `eldoc-documentation-compose': calls all the functions in the ho= ok,
=C2=A0 and displays all of the resulting doc strings ...

This doc string doesn't explain the use of the timer, it explains the reason for its existence.=C2=A0 It should also describe the use:

> +(defvar eldoc--enthusiasm-curbing-timer nil
> +=C2=A0 "Timer used by `eldoc-documentation-enthusiast' to av= oid blinking.")

Last, but not least: the "async" part of the branch's name hi= nts on
some advanced and extremely useful functionality that these changes
are supposed to allow, but I see no mention of that in NEWS and in the
manual bits.=C2=A0 What did I miss?
--000000000000ea6e9b05a99a2bab--