From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Kangas Newsgroups: gmane.emacs.bugs Subject: bug#23430: 25.0.93; iter-defun does not support special form save-current-buffer Date: Tue, 11 Aug 2020 19:41:39 -0700 Message-ID: References: <86k2jc2ahf.fsf@yandex.ru> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="9268"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: 23430@debbugs.gnu.org To: Dmitry Gutov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Aug 12 04:42:26 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 1k5gig-0002KC-79 for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 12 Aug 2020 04:42:26 +0200 Original-Received: from localhost ([::1]:47594 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1k5gif-0003Jn-93 for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 11 Aug 2020 22:42:25 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:48020) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1k5giI-00030c-Oe for bug-gnu-emacs@gnu.org; Tue, 11 Aug 2020 22:42:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:59043) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1k5giI-0004m9-FC for bug-gnu-emacs@gnu.org; Tue, 11 Aug 2020 22:42:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1k5giI-0001ts-Db for bug-gnu-emacs@gnu.org; Tue, 11 Aug 2020 22:42:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Kangas Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 12 Aug 2020 02:42:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 23430 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: moreinfo Original-Received: via spool by 23430-submit@debbugs.gnu.org id=B23430.15972001067273 (code B ref 23430); Wed, 12 Aug 2020 02:42:02 +0000 Original-Received: (at 23430) by debbugs.gnu.org; 12 Aug 2020 02:41:46 +0000 Original-Received: from localhost ([127.0.0.1]:42355 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k5gi2-0001tF-8h for submit@debbugs.gnu.org; Tue, 11 Aug 2020 22:41:46 -0400 Original-Received: from mail-yb1-f174.google.com ([209.85.219.174]:45069) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k5gi0-0001sr-VU for 23430@debbugs.gnu.org; Tue, 11 Aug 2020 22:41:45 -0400 Original-Received: by mail-yb1-f174.google.com with SMTP id x2so539700ybf.12 for <23430@debbugs.gnu.org>; Tue, 11 Aug 2020 19:41:44 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:in-reply-to:references:user-agent :mime-version:date:message-id:subject:to:cc; bh=WZOHPvkFXvBfKD61/Fwo58HoZ20zlL4rZlTmnifUXJo=; b=Iowug01NsP27rE7a2FHIECTHZWbh3mcqbWx9ZR7O+Ju5vYK3zPJuEQc+iY8AukLn+C SH5r0UMqFuGYzyAi9VH0nj4dl4GVc0rRuZBoZsUUcfYgyRx/YWyJiT7F0lkuqJM34UOj ZBXNWGK3lVOsZzF6f0NunuwXv2vt+nIYVOLfbcslHnoiCQA934QjDuny1FQb2YNFQ3+L bPEUSX1/3Pe03LhO4lKGQhtWXPM+ujkeG8Z2Y5UDhoP0mDO3R4UQ8KIBqp2QSytz3ZD5 BpHUxfyuMmhLhLF4bZOpR6Kj5+ZDiCTXsalaIgc6ny5oV6Lr8ZrQVxOaUBFsNekVJui9 nj/g== X-Gm-Message-State: AOAM530EtaQ5p7KgHpD71Zz+ruZZwpFHY6hXcogxhVTpARGqGkL61LDe 3jXIn+azhicbexSr9uxsiN/fHQf5HUISs81+sRM= X-Google-Smtp-Source: ABdhPJyGTzZJDxOFHyLEVSgHokbfIIjpWwvLnuj7EXKoGXQofrfKuNDXbUMvYrmrwJeFygQKQyIlqQI/WQD4JTJBLyg= X-Received: by 2002:a25:880e:: with SMTP id c14mr53947471ybl.181.1597200099633; Tue, 11 Aug 2020 19:41:39 -0700 (PDT) Original-Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Tue, 11 Aug 2020 19:41:39 -0700 In-Reply-To: (Dmitry Gutov's message of "Fri, 6 May 2016 01:46:54 +0300") 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:184730 Archived-At: Hi Dmitry, Dmitry Gutov writes: > On 05/03/2016 04:31 AM, Dmitry Gutov wrote: > >> The above example seemed to me to be the prime use case for generator.el >> (e.g. lazily parsing output from an asynchronous process), so this >> is disappointing. > > Actually, I take this back. > > - generator.el doesn't seem useful for parsing output from an asynchronous > process because it has no way to indicate whether the process has new output, > or to return control back to Emacs while the process is still running but has no > new output. It seems to call for a different abstraction. > > - with-current-buffer turned out not to be so essential. Nor > save-excursion. I've reimplemented xref--buf-pairs-iterator using > iter-lambda but couldn't get the full benefit of the package because that > function also needs a way to reliably clean up resources. The result is a bit > more comprehensible, but also longer, so I'm hesitant to use it (attached). > > So sum up, maybe this bug can be closed, but I'd like to see Daniel's > opinion. Supporting with-current-buffer might turn out to be more > essential in other cases. Is this patch still relevant or should this be closed? Best regards, Stefan Kangas