From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham autolearn_force=no version=3.4.2 Received: from primenet.com.au (ns1.primenet.com.au [203.24.36.2]) by inbox.vuxu.org (OpenSMTPD) with ESMTP id 7a55574b for ; Thu, 23 Jan 2020 09:54:22 +0000 (UTC) Received: (qmail 21374 invoked by alias); 23 Jan 2020 09:54:14 -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: List-Unsubscribe: X-Seq: 45341 Received: (qmail 19112 invoked by uid 1010); 23 Jan 2020 09:54:14 -0000 X-Qmail-Scanner-Diagnostics: from mailout2.w1.samsung.com by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.102.1/25699. spamassassin: 3.4.2. Clear:RC:0(210.118.77.12):SA:0(-7.0/5.0):. Processed in 2.18538 secs); 23 Jan 2020 09:54:14 -0000 X-Envelope-From: p.stephenson@samsung.com X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | Received-SPF: pass (ns1.primenet.com.au: SPF record at _spf.samsung.com designates 210.118.77.12 as permitted sender) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout2.w1.samsung.com 20200123095335euoutp0233268b16a2b131362642d53eef0244f0~se16HM-n51467014670euoutp02b X-AuditID: cbfec7f4-0e5ff7000001ed07-f1-5e296d1e85e5 Message-ID: <1579773213.5343.1.camel@samsung.com> Subject: Re: Unset =?UTF-8?Q?=E2=80=9Czle=5Fbracketed=5Fpaste=E2=80=9D?= .zshrc From: Peter Stephenson To: Date: Thu, 23 Jan 2020 09:53:33 +0000 In-Reply-To: <20200123031249.034c7e1a@tarpaulin.shahaf.local2> X-Mailer: Evolution 3.18.5.2-0ubuntu3.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFnrPIsWRmVeSWpSXmKPExsWy7djPc7pyuZpxBrOXm1kcbH7I5MDoserg B6YAxigum5TUnMyy1CJ9uwSujONz7rAVfOSquLOsmamB8QNHFyMnh4SAicTpGdvYuxi5OIQE VjBK3O66yQzh9DFJnH43HyrTyyRx980BRpiWc63NrBCJ5YwSv1u3McJVrZp9Bqr/DKPEt74D UJkLjBINux+wgPTzChhK7Ji1nqmLkYNDWCBQYkenMkiYDSg8ddNssBUiApIS15pPg9ksAqoS y35MZwKxOQXsJC5M3AB1hobEhpvHmCBGCkqcnPkEbDyzgLxE89bZYEdICDxmk+ja8AaqwUVi z7+zLBC2sMSr41vYIWwZif875zNBNLQzSqyZ9JodwulhlNh09A5Ut7VE3+2LjCBXMwtoSqzf pQ8RdpT4fXUCO0hYQoBP4sZbQYgj+CQmbZvODBHmlehoE4KoVpPY0bSVESIsI/F0jcIERqVZ SD6YheSDWQirFjAyr2IUTy0tzk1PLTbKSy3XK07MLS7NS9dLzs/dxAhMBqf/Hf+yg3HXn6RD jAIcjEo8vA6WGnFCrIllxZW5hxglOJiVRHgZwzTjhHhTEiurUovy44tKc1KLDzFKc7AoifMa L3oZKySQnliSmp2aWpBaBJNl4uCUamC03zW5vHdbnubvj1s0fl19Ibm840X5ixSrf7ffTvP4 GNquKZt9boWGe/HDLSkbWWdYB2onXOZ45ndNb9HnA78V/zzsT9c637fmayuTf4EXT5ZP+fue 6EW5D4ouzleRdJdLsvy7b9eO5Kf5zG5b5rPZcr4P5ai6GBr7+tjNS/ZTTaTC1nrOl72sxFKc kWioxVxUnAgAuT6LkgIDAAA= X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFmpikeLIzCtJLcpLzFFi42I5/e/4XV25XM04g6mflCwONj9kcmD0WHXw A1MAY5SeTVF+aUmqQkZ+cYmtUrShhZGeoaWFnpGJpZ6hsXmslZGpkr6dTUpqTmZZapG+XYJe xvE5d9gKPnJV3FnWzNTA+IGji5GTQ0LAROJcazNrFyMXh5DAUkaJC/e/s0IkZCQ+XfnIDmEL S/y51sUGUdTNJLFs9T1mCOcMo8SrbU0sEM4FRomV1++DtfAKGErsmLWeqYuRg0NYIFBiR6cy SJgNKDx102xGEFtEQFLiWvNpMJtFQFVi2Y/pTCA2p4CdxIWJGxghZjYxSTx/NRdsJrOApkTr 9t9QJ2lIbLh5jAlil6DEyZlPWCBq5CWat85mnsAoNAtJyywkZbOQlC1gZF7FKJJaWpybnlts pFecmFtcmpeul5yfu4kRGP7bjv3csoOx613wIUYBDkYlHt4XZhpxQqyJZcWVuYcYJTiYlUR4 GcM044R4UxIrq1KL8uOLSnNSiw8xmgJ9NJFZSjQ5HxibeSXxhqaG5haWhubG5sZmFkrivB0C B2OEBNITS1KzU1MLUotg+pg4OKUaGM0LV0gl3784QeD+85msNvlmHJUdT0/lJkcoJ59ep3zM 6pO/VYd1YM4V/kkd3W8TW68/fPXCjO2dqauCA2vU6027BE3YDG9HaLB53Ju1aGbeSe4lh13C tv1pVUz6lN6s7/z7NNu0T3tvWympb1+5vOyV58Gaj5Eh/xqmTxFb86XtQNSF66dLa5VYijMS DbWYi4oTAXAzBHGVAgAA X-CMS-MailID: 20200123095334eucas1p2f6660287a25197b1e7b56b022d310dc8 X-Msg-Generator: CA Content-Type: text/plain; charset="utf-8" X-RootMTR: 20200123031354eucas1p1605fb92fcf91bd7e2f1b13677b6cc244 X-EPHeader: CA CMS-TYPE: 201P X-CMS-RootMailID: 20200123031354eucas1p1605fb92fcf91bd7e2f1b13677b6cc244 References: <0723EF0A-BD62-4C2C-AAA1-735AD3D64768@icloud.com> <20200123031249.034c7e1a@tarpaulin.shahaf.local2> On Thu, 2020-01-23 at 03:12 +0000, Daniel Shahaf wrote: > I haven't tried to implement this yet, but what I have in mind is > (1) Make unsetparam_pm() add the PM_UNSET bit if the PM_AUTOLOAD bit is > present; (2) Make module loading, before creating a parameter, check if > there's a Param with PM_UNSET and PM_AUTOLOAD both set; if there is, > rather than create the "real" parameter, delete the tombstone parameter. > (But if there isn't a Param at all, the module _should_ create its special > Param anyway, to allow modules to be unloaded and reloaded in the same > shell session.) The obvious expected behaviour would be for it to have the same behavious as unsetting the parameter after the module is loaded.  But a quick tests suggests that doesn't work for readonly parameters, for one --- all that would happen is that would produce an error when the module is loaded, which doesn't really make much sense.  So in that case, at least, the behaviour above is as logical as anything. Documenting the current behaviour is perfectly respectable.  The autoload flag effective means the parameter behaviour defers to the module.  Remember, you can use zmodload -F to manipulate which features are provided by a module, although not at the point of declaring autoloads --- some sort of autoloadable feature set might be another way of doing this. pws