From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Jim Porter Newsgroups: gmane.emacs.devel Subject: Re: continuation passing in Emacs vs. JUST-THIS-ONE Date: Thu, 16 Mar 2023 22:37:16 -0700 Message-ID: References: <627090382.312345.1678539189382@office.mailbox.org> <87sfe7suog.fsf@gmail.com> <1c6fedae-10b4-5d97-5036-eaa736e1b816@gmail.com> <87mt4c6xju.fsf@logand.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="9240"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Karthik Chikmagalur , Thomas Koch , "emacs-devel@gnu.org" To: Stefan Monnier , Tomas Hlavaty Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Mar 17 06:37:59 2023 Return-path: Envelope-to: ged-emacs-devel@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 1pd2ms-0002Il-VT for ged-emacs-devel@m.gmane-mx.org; Fri, 17 Mar 2023 06:37:58 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pd2mJ-0002nO-MR; Fri, 17 Mar 2023 01:37:23 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pd2mH-0002db-HC for emacs-devel@gnu.org; Fri, 17 Mar 2023 01:37:21 -0400 Original-Received: from mail-pg1-x52e.google.com ([2607:f8b0:4864:20::52e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pd2mF-0002p3-Ob for emacs-devel@gnu.org; Fri, 17 Mar 2023 01:37:21 -0400 Original-Received: by mail-pg1-x52e.google.com with SMTP id d8so2266139pgm.3 for ; Thu, 16 Mar 2023 22:37:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1679031438; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:mime-version:date:message-id:from:to:cc :subject:date:message-id:reply-to; bh=Zj/GSeMrsXyxKpeTufppEaiRM2lu7mGLQ1Ud8TduZ7g=; b=b7GBvpUGFmFstigDPI4ocEWariVGNS3nyGM+hWYbE5ywb85ffsELGAGh8WTDrd1TCE Lho2PHwKpiLzfnDQ2m49GpxTf5yJ02JjN0lPJCHRJGhCfootTijg2Ger7vDu6KUPcVaO u11q2ttghvyMddxkKQgXSrPtGh8hdJxspwDBUkFdKrz+0OlW/tABXS40Xn6jPYtFaIzn tefZTosIrzIkjFFNzvVzWhAkvU+NW1V+1KpnsIxn9D5TuFzf1PuZSOIu8QF9RvfWvBYY A/h98qQaxiULo59xal0he+1/MsOHZKkcSv8zkxZP/sQbiOBBoMTZLdmSyBLKVF1NEcsP CuOA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679031438; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=Zj/GSeMrsXyxKpeTufppEaiRM2lu7mGLQ1Ud8TduZ7g=; b=N8wiMUtFP+elbCWurnM25woGkPB3ASxnq//1ZW2ZUaVBp9+JKWnOTOfqyRqdWhwOAm BsKYBIMnQvfdl3BEJR9wNJM/NqWePbHT0G1oE2myvNsZ4l3W97O2i6+vdbx+B70JpCW8 7f20v9SBIUP/tznGWqxow2kwjPD1+yBRNlRq35idU5pZotdINrKjqmzMq9sIOhOlJURD JJesk3u9mtzpYGVC2ACzjdXb5P+s3Zy1lxk2DNfhYjGnYUgMNVem9+snglInbabcL6zU WIlet5CGcBXeagbSgIhyDy7Z7wd3vX9dv1PTJ0npEe6yxEWZiG/gmTQorth/hpPKVHqI vNHQ== X-Gm-Message-State: AO0yUKWJDULCTxgxuhgS0XMVRUno33f1OJgHMqr7r5O5Ij7CGMXWnqgP XSrKH40ciugBIXRAoFZruGI= X-Google-Smtp-Source: AK7set8+s/q8vmHciftEVxF8iVs1Pd703nTtNHPmFkjTG9+v8YMxc65DVB7+9ebCDiNPSsXCrasNYg== X-Received: by 2002:a05:6a00:4388:b0:622:6cc8:2393 with SMTP id bt8-20020a056a00438800b006226cc82393mr1901747pfb.5.1679031437834; Thu, 16 Mar 2023 22:37:17 -0700 (PDT) Original-Received: from [192.168.1.2] (cpe-76-168-148-233.socal.res.rr.com. [76.168.148.233]) by smtp.googlemail.com with ESMTPSA id a3-20020aa780c3000000b005ded5d2d571sm605507pfn.185.2023.03.16.22.37.17 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 16 Mar 2023 22:37:17 -0700 (PDT) Content-Language: en-US In-Reply-To: Received-SPF: pass client-ip=2607:f8b0:4864:20::52e; envelope-from=jporterbugs@gmail.com; helo=mail-pg1-x52e.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 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-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:304536 Archived-At: On 3/16/2023 8:08 PM, Stefan Monnier wrote: > BTW the above code can't work right now. Part of the issue is the > management of `current-buffer`: should the composition of futures with > `futur-let*` save&restore `current-buffer` to mimic more closely the > behavior one would get with plain old sequential execution? If so, > should we do the same with `point`? What about other such state? How about doing what threads do? > Each thread also has its own current buffer and its own match data. If nothing else, consistency makes this easier to remember. (And if more stuff should be saved and restored, it would probably be good to add those to threads too.)