From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1250 invoked by alias); 15 Nov 2016 22:07:20 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 39953 Received: (qmail 9105 invoked from network); 15 Nov 2016 22:07:20 -0000 X-Qmail-Scanner-Diagnostics: from mail-ua0-f171.google.com by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.99.2/21882. spamassassin: 3.4.1. Clear:RC:0(209.85.217.171):SA:0(0.0/5.0):. Processed in 0.68445 secs); 15 Nov 2016 22:07:20 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_PASS,T_DKIM_INVALID autolearn=unavailable autolearn_force=no version=3.4.1 X-Envelope-From: schaefer@brasslantern.com X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | Received-SPF: pass (ns1.primenet.com.au: SPF record at _netblocks.google.com designates 209.85.217.171 as permitted sender) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=brasslantern-com.20150623.gappssmtp.com; s=20150623; h=from:message-id:date:in-reply-to:comments:references:to:subject :mime-version; bh=yfP/h+6iNBmdkTMRr1Jk6NIn0DGLXSf51pjyzpk5/lw=; b=XwKlRaE8MH8Tj9pQHcgq3X7n7Hk+m/c9b+HkI3hyWGjKAZGPm0NsLSJpBxV1gZTjKB KIf0zY0VhCzzcHKWmL60jiyNNh6T7CS1Des9HYK/2eJfrPMFhRykG2twPymbAfU1g+k+ HVR/4BWCrjU/OzvJCizC8HR5UaizP/WpD1ibnvpOcFecJxczpBmfksvQkdJL+3RCV7kE YTnicu6KcfOnN6GldSvQRNOKAeNM6bpUQMK7++zj9E0Z+oIv1IVAWlTbHIFSpZAMCLNv 2psfQpqRrlexJcjG68O8H8rmMmvrdqi1GsOcZQ3gh18c/SASKsgsxH0YSi4Uijsn6XSh drbA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:message-id:date:in-reply-to:comments :references:to:subject:mime-version; bh=yfP/h+6iNBmdkTMRr1Jk6NIn0DGLXSf51pjyzpk5/lw=; b=JT6Tzjdj8gwSXNr3v/vCsou/GHW4Sp5Zdml8Wiz7IuiRMwc6Cwl0vEQmgO1eQ3hkRJ Pl6LByixtEAw3atAjr3ww7uLvrQl+1ZaZTkznxuxiHvBuaq0lHrxyMp0kCErx7QdxxLK q144Uq2Jjo54fItkIYEMewaNHPLWwhr1J1xD6U/sxKu3g+4xZ60zr3EwfagGxJKJNVTs 0asxPsI1e/vLObLlwlaaspnj1LpYV0iuLaOHTttBxUeccM6+GW6gR5p/Le8ZQi8J/wbS BXE8sBBvVEhXMIJ9SFC2mLvTuqBnmukGeSSYf1+i7hA0tO02ZKiUNVH5l3o7Pr8i7agt z6tA== X-Gm-Message-State: ABUngvdjbtJoUCy4oRR9dlBlr2NKAphvZRFB4P4mkh1qebNjYjZoydJY55JvfUzX20Aqgg== X-Received: by 10.159.36.108 with SMTP id 99mr14890260uaq.124.1479247633094; Tue, 15 Nov 2016 14:07:13 -0800 (PST) From: Bart Schaefer Message-Id: <161115140723.ZM11274@torch.brasslantern.com> Date: Tue, 15 Nov 2016 14:07:23 -0800 In-Reply-To: <22835.1479246117@hydra.kiddle.eu> Comments: In reply to Oliver Kiddle "Re: Shift-Insert overwrites ZLE CUTBUFFER" (Nov 15, 10:41pm) References: <161025091249.ZM7232@torch.brasslantern.com> <161026090133.ZM11120@torch.brasslantern.com> <161026165138.ZM12130@torch.brasslantern.com> <87h97x36sa.fsf@lwm.klanderman.net> <161027133523.ZM15655@torch.brasslantern.com> <43312.1477929414@hydra.kiddle.eu> <20161031161605.23af1751@pwslap01u.europe.root.pri> <161109092745.ZM2477@torch.brasslantern.com> <4446.1478794906@hydra.kiddle.eu> <161110091736.ZM20932@torch.brasslantern.com> <22835.1479246117@hydra.kiddle.eu> X-Mailer: OpenZMail Classic (0.9.2 24April2005) To: zsh-workers@zsh.org Subject: Re: Shift-Insert overwrites ZLE CUTBUFFER MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii On Nov 15, 10:41pm, Oliver Kiddle wrote: } Subject: Re: Shift-Insert overwrites ZLE CUTBUFFER } } On 10 Nov, Bart wrote: } > A useful addition to zsh/zleparameter would be a special hash of } > register-to-content mappings (emacs calls this register-alist). } } The following patch adds this under the name "registers" [...] } For what it's worth, I think the term } "registers" is better than "buffers" and it'd be good to use the same } ones with emacs style widgets. I don't have any particular quibble with this, except that the names of the vi-widgets all refer to "buffers" and it would be annoying to change them. As a thought, could use the terms "killring buffer" for 1-9 and "register buffer" for a-z, when updating documentation. (Although it's possible to expand the killring to more than 9 elements by assigning directly to the variable.) } What does the "alist" part of the emacs name denote. For practical purposes, it means the same as ${(kv)registers} after your patch: a list of alternating key-value elements. } It contains just the registers 'a' to 'z' for now. Including the } numbered registers would just be a duplication of killring/CUTBUFFER. } (except the yank register - "0). Aside: If the numbered registers duplicate $killring, how is it there are 9 numbered registers but the killring defaults to only 8 elements? } Why does makezleparams set pm->level to locallevel + 1? That seems } wrong. What does the + 1 achieve? The parameters are created before the function for any user-defined widget is called, but are defined as being local to the scope of the user-defined widget. Or at least that's my understanding, it's been a while since I walked through the flow. Anyway, the point is that the ZLE parameters hide (rather than refer to) any existing parameter of the same name, and are always local.