From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.3 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 16166 invoked from network); 28 Apr 2021 18:16:07 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 28 Apr 2021 18:16:07 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20200801; t=1619633767; b=zNBFbReNAtkoaau4oCRfWiclRq4iSupA4G7kfYpP+F3Lya6pmJ0aW7esgEy0WHoMxv6cKCTe07 HJT591ZnWDtMHANTI55DpK1eIZx/c0gYS5NeJEeLDpyWnklMtPeeM0gyPEQu6myIfwasUrTXwC pLEN5ZW6Bi9SPmcU5+8KG5Ti4D6GuIuKmWwVyOgZV0K6g2qQ09I3N0Er3wwGlnwUZ5Sydw9c2i VB/Eyu/Og4nSCnqRQxFBcyEBC9d/Av/jBY9UbvdQJ00tPSqi7fHWam/nz9YyljjM71Hku5c+tB igxJUO3ScAWAtqX9+w2c0qDada/NhKjoqLEOU45tJuuuvQ==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (mail-ot1-f45.google.com) smtp.remote-ip=209.85.210.45; dkim=pass header.d=brasslantern-com.20150623.gappssmtp.com header.s=20150623 header.a=rsa-sha256; dmarc=none header.from=brasslantern.com; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20200801; t=1619633767; bh=IKoSJFj66hhH2Ck5LCookbBisrWkOQq8jJkC0opFZgU=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Type:To:Subject:Message-ID:Date:From:In-Reply-To: References:MIME-Version:DKIM-Signature:DKIM-Signature; b=vfUlDnPf9FlcmgWXRM9EOLIFkkXHpAHMf6BwX8AtANxvr+6yByw74vjbinFw0c2FY2qLpNE+m0 oh++Ry4ga717LJ/pYYJLxNQcuOYpTrIN9u0zmQVy0rRQY8PAhFN1HzZspEGYufNz0mt79Y/ghr WzaN+TvUC4NREyXHSz8WuUwJM1/WzMcZVvRX/4xawuJnMa08eDsNV5i0f4DWxij7wuGRlgbJHs 4oQoPdDSU2HyHOqk/pDthxjKdWQfqyThEMuqXKHj0jjdPNR0DStsXmXMNsl7El/2RiK6rGw/8m bAEQhHQR6HTgxSKrwSwTGME8Vms2xzK1LqHo4ZNAUTdtmg==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20200801; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:Content-Type:To:Subject:Message-ID: Date:From:In-Reply-To:References:MIME-Version:Reply-To:Cc: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=8/L+9iNLg2MXysz8PkpXc2yCWjTymwFAXF7aK6DF0VY=; b=Nglv0g09M8CKZK4BNm725PMydi irJNAYnLgr+re+YryO7VVcUuFqcJsNGLEXDT+Td7n0pK9tkDWGho+RaPQSNf74btoK4CmA317SpaB 4CrWmf2sGK7ba146CjFiUBQySWf5K/Z1VWN6aBgoT5iAyhQNLz1rCAoN4zbnMA7mbJKQ8s8TztVXe FSPsgYNBbVa/w41wHUkFGh2kTmgRxrdaLabY1CyAyXxiybYMqSCBjb0ji8NpIk4vqOJE68ENT/jxc mbtcQQK0giJvqT6nRAV2m13mEVj5aysqNTzWqrmHD/3hczoMCIjkL13AoNN0hAfWG2jevghy1Rnmj EKsKcCnQ==; Received: from authenticated user by zero.zsh.org with local id 1lbojF-000PS1-Db; Wed, 28 Apr 2021 18:16:05 +0000 Authentication-Results: zsh.org; iprev=pass (mail-ot1-f45.google.com) smtp.remote-ip=209.85.210.45; dkim=pass header.d=brasslantern-com.20150623.gappssmtp.com header.s=20150623 header.a=rsa-sha256; dmarc=none header.from=brasslantern.com; arc=none Received: from mail-ot1-f45.google.com ([209.85.210.45]:38621) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_128_GCM_SHA256:128) id 1lboij-000PCh-PM; Wed, 28 Apr 2021 18:15:35 +0000 Received: by mail-ot1-f45.google.com with SMTP id v23-20020a9d60570000b02902a53bac99a3so4425236otj.5 for ; Wed, 28 Apr 2021 11:15:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=brasslantern-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=8/L+9iNLg2MXysz8PkpXc2yCWjTymwFAXF7aK6DF0VY=; b=U8sX7eWQkuRymP+oSy7/TzClMfUvSEt/aXFPgFapRePFUxf38MY4in2J/Tuw4O08b0 dQwJWNT1nZmc3fGBDEL8rilRGARX8uZKKLVgds3CkI7C6BBuSVevPBFgwDgKipF+LOo4 s011ZhkVDtLEZv4V+6la5nZ6xX1FDTg3KB2A/+Ymvs73T11PtofP0SNuHX5M1MlWdT// he6nlZ2TcqOah79NZ8qHRvYCxJFXXKO3Ho+144OOmjPxbiOvgWnevXf9d4VSa+Okca1S hRIY1tljnsYCgF6Ib9yk2QNcQEkTmzJxX8JN7LO6UrRrjYcDYqtA9NTE5yXGm9t/jou5 mvgQ== 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; bh=8/L+9iNLg2MXysz8PkpXc2yCWjTymwFAXF7aK6DF0VY=; b=BWpJ1OQM+QKYumqkwmxjzxGu4OclZRTzO5HDGm6Je7zj1aoxxAugJfg7fGAfECLFwo Y4MMbR/uuLP//aFqzZvUIREY7q9zR8wXmaeYLbzGu6O1jGoH0MVQbyVb3gFZ0oI278tw hQjGuUKqoUqExQermo68lAQeEJQfE4bzEQPdXEi/poDBf5vTonbcnE7Tq7+ftbPyUjcg KAE0DudvK0tXc1AAgSaGpwfppeBMKO7s3UFslbwnT5SuU6RLwAg56utHo+pcQH0hmbIO R/eCJrMvPEzZqn9ydgCjJe+Jok5Zf2bh5Y3rVACjzNXXDKZn1zrBggvcdHOSNPlske3D G9Ew== X-Gm-Message-State: AOAM533TrFZhj2dsW7vzaGUkH3TA+pPXUdy1uUVWbb+7fkQ7eqz13a3H Lrqb8RFzgXiFS3r1LtGBHx0mbFY2YDa4fgzH8CAPxA== X-Google-Smtp-Source: ABdhPJxJk/wI2cjt7zOYo6G4Otutg5SF4vZNjP3Z8w0wyTLnTI7PZ/npcbEEc6n4B3EmLA9y9nn6lEj112rCOCA0+m4= X-Received: by 2002:a9d:a4e:: with SMTP id 72mr24619798otg.229.1619633732035; Wed, 28 Apr 2021 11:15:32 -0700 (PDT) MIME-Version: 1.0 References: <20210428072605.rznyqipd2kuv2vig@chazelas.org> In-Reply-To: <20210428072605.rznyqipd2kuv2vig@chazelas.org> From: Bart Schaefer Date: Wed, 28 Apr 2021 11:15:20 -0700 Message-ID: Subject: Re: The curious incident of the feep in the night-time To: Bart Schaefer , Zsh hackers list Content-Type: text/plain; charset="UTF-8" X-Seq: 48736 Archived-At: X-Loop: zsh-workers@zsh.org Errors-To: zsh-workers-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-workers-request@zsh.org X-no-archive: yes List-Id: List-Help: List-Subscribe: List-Unsubscribe: List-Post: List-Owner: List-Archive: On Wed, Apr 28, 2021 at 12:26 AM Stephane Chazelas wrote: > > That reminds me of > https://www.zsh.org/mla/workers/2020/msg00229.html > (X-seq: zsh-workers 45404) Following that back to https://www.zsh.org/mla/workers/2015/msg00843.html (workers/34919) > ... using a different [errflag] bit ... we could abort back to > the top of ZLE rather than out of ZLE and back in again That idea is actually impossible because of the aforementioned handshake with the parser. Unwinding the recursive-descent parse requires leaving and re-entering ZLE. > which would > mean you finally had the ability to embed push-line in other widgets (This means "push-input", push-line actually already can be embedded because it doesn't reset the prebuffer.) I think the best we can do without completely restructuring the interactive shell input** is to avoid treating push-input / push-line-or-edit as an error condition, which might make it possible to fix the "vared kills the shell" problem from workers/45404. ** Roughly, we'd have to invert the entry chain so that ZLE drives the parser instead of the other way around, and change accept-line so that it doesn't leave ZLE at all until the parser says it has a complete expression, with attendant changes to managing PREBUFFER and BUFFER and the printing (or not) of PS2, etc. That in turn means that interactive input is handled a lot differently from script input, whereas right now those differences are all restricted to the I/O layer.