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.4 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 22072 invoked from network); 15 Apr 2021 18:39:17 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 15 Apr 2021 18:39:17 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20200801; t=1618511957; b=be06St9pCXrNysPB6k1Bp9AjcvILtgQq375+HkDJgmMqC49gJMTDHX91I/caG5W4WXY8JGEjEO QQ9/JdNwW91b8ZVe9eEOcvoD+HuVEcBZWWNoXhSmHV5WCA8nCjrdZOZL9hVPNL5XJsXPj9D2M4 L4NLdfmEJmFl+Kf5vVi6L4KJZtEzYZ66/963uOY3oDZldj8CjYxnKxedXiYwEj14DcFLcfYgJO BrE5FFJD6i7m0gt1VJbf+idLH74xOIDdwQAloJKv7jH1iQvbrZokOfSYrrxtOI7LIFGLVk/l01 Cg/G3YAPamEYJik82Bz6zmsRRaGZRO26sjePezBS1qmMdA==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (know-smtprelay-omc-11.server.virginmedia.net) smtp.remote-ip=80.0.253.75; dkim=pass header.d=ntlworld.com header.s=meg.feb2017 header.a=rsa-sha256; dmarc=pass header.from=ntlworld.com; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20200801; t=1618511957; bh=NjVa9XBFBGCWEnBmqNg7yk5o6P6rK7cdQi6Yr1obbR4=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Transfer-Encoding:MIME-Version:Content-Type: References:In-Reply-To:Date:To:From:Subject:Message-ID:DKIM-Signature: DKIM-Signature; b=aM9hQiahPfeHcqPM94tdl4933QbtHl5FD0nfpfCkh/0WW1Fb5aHAs7GX6A1yCPlywtImMRLdT/ FqkQVb6nSq8zAbLsaFLH9mHek1ZNcda6CN/KjqzkqY+7Mp/6lvzCaGKoB8AwZ4EK1bEy23eaD8 Wtnv085KuY1DBn+SE0pAZSwtGWMectGO+gkUv2StMjlQq6vUIneeH6YtbO2+xqvoe8PR9Amkey Ns4sXgXzn9xr6ZxC3Dy8oKb1uDmxhTwnKC89OklgcRjqZxQaeSziSWpZc7vN58zePtpIs7bHoc L9wdFHozeq8kh/k4/NEuEEQ1nmPqWXdmzt2YKPxBsFQYmg==; 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-Transfer-Encoding: Mime-Version:Content-Type:References:In-Reply-To:Date:To:From:Subject: Message-ID:Reply-To:Cc:Content-ID:Content-Description:Resent-Date:Resent-From :Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=Z0qnJ4CDsQYr8YuYQKoTI+I/fuJkf2JbrTpKcpeNR3E=; b=UHcE5ky2vzSJLVuNTW7L1GOCT5 m0GVFqxTjaJhJNmTuzEhYyihs6LYZNwqTWcN20j5NfPMQZ5GYvya2Q76Hr1yU0mb2WpVk3p4gTVNd 6H9Qj4ypBEIoAkD2JdNK/ld+ozFUEKD2Y+Gx4uFnzaiVqRlwcGYcu7tNv2yL0x7bGNTzeHrGnysNk 9gScw9BG/An2bSDu8pvHwjR+dWB+XrYagTGw4q9/++3tTYOBufVwR5uiNz1t3SAcPb590S8kI5v9b VtRx3XiqnfJ10ygklVeSYFSONDFGlHZjack4J+yUZpFFVI16yl26Ra5RuruPNDY7uvS61jxdNkb4A qKA2aThw==; Received: from authenticated user by zero.zsh.org with local id 1lX6tY-000Hsv-BY; Thu, 15 Apr 2021 18:39:16 +0000 Authentication-Results: zsh.org; iprev=pass (know-smtprelay-omc-11.server.virginmedia.net) smtp.remote-ip=80.0.253.75; dkim=pass header.d=ntlworld.com header.s=meg.feb2017 header.a=rsa-sha256; dmarc=pass header.from=ntlworld.com; arc=none Received: from know-smtprelay-omc-11.server.virginmedia.net ([80.0.253.75]:38122) by zero.zsh.org with esmtps (TLS1.2:ECDHE-RSA-AES256-GCM-SHA384:256) id 1lX6sp-000HcB-UA; Thu, 15 Apr 2021 18:38:32 +0000 Received: from pws-Zeus ([82.20.19.64]) by cmsmtp with ESMTPA id X6sml0dVSOvGxX6splkw5x; Thu, 15 Apr 2021 19:38:31 +0100 X-Originating-IP: [82.20.19.64] X-Authenticated-User: p.w.stephenson@ntlworld.com X-Spam: 0 X-Authority: v=2.3 cv=RZUk9Glv c=1 sm=1 tr=0 cx=a_exe a=FYxK54AnRTbDA0SLc6W5Eg==:117 a=FYxK54AnRTbDA0SLc6W5Eg==:17 a=IkcTkHD0fZMA:10 a=Z193yC-_ia4G9U8PO3sA:9 a=QEXdDO2ut3YA:10 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ntlworld.com; s=meg.feb2017; t=1618511911; bh=Z0qnJ4CDsQYr8YuYQKoTI+I/fuJkf2JbrTpKcpeNR3E=; h=Subject:From:To:Date:In-Reply-To:References; b=Uwz1bJmUAvJbtfFL1yodSeQYy/8P0YFmGSBH8ETqhlJ8aiCS7rQJbYfaYQzM39Tal gjuBiDRkPCKdMf8adiUdzAUhjSBKankp4G5k6CjfavYX69840cAP4ZbTdryh73kVCK w/+Vl7MzhzAJGGoRRT56va+v8FydBIN9atTZM2wV9yPaxkZOQeoOi6WpCpCxuVHcqW oZbd+lxHeuAjrf9mItimeAZuvHaiygVeXqttH/TNZJwb0ptL/lTyw+gFNuGyoaGgPt tFoY4P5vW9DFZqFmxZKmpYWFtmvj+RPk/UMqFd98mBj1Q0EM6OEGJTTRx/R42U9E2j kqoQDhFRJKTYA== Message-ID: <2d162aaf0f19dfc18b6ee72d35b77d454307546c.camel@ntlworld.com> Subject: Re: PM_TAGGED and PM_TAGGED_LOCAL being set simultaneously (functions -T -t f) From: Peter Stephenson To: zsh-workers@zsh.org Date: Thu, 15 Apr 2021 19:38:28 +0100 In-Reply-To: <20210415162115.GB1002@tarpaulin.shahaf.local2> References: <20210414150337.GA23748@tarpaulin.shahaf.local2> <994269365.178120.1618413776846@mail2.virginmedia.com> <20210415162115.GB1002@tarpaulin.shahaf.local2> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5-0ubuntu0.18.04.2 Mime-Version: 1.0 Content-Transfer-Encoding: 8bit X-CMAE-Envelope: MS4wfA+jB7vj2M8DK/picnnpOcM4lyRpCTD/Ti09d/duvLCJLrNG4GV9ZjT4nQ09H/6+VcXpj+h7/kBc4VTVULjv3cxQGDOQpuie9tFiYanB3fVP1D43i+8v XML31TBGr8BJU9GMANNaMH6mx26vpy+G4tUlISwYit/yxPbyrsQgA4re X-Seq: 48591 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 Thu, 2021-04-15 at 16:21 +0000, Daniel Shahaf wrote: > > > f() g > > > g() : > > > functions -T f > > > functions -t f > > > f > > > > > > Should XTRACE be on or off when g is run? Or should an error be raised > > > before g is called? > > > > > > And if -t were set first and -T second? > > > > The way the documentation is written: > > > > The flag -t turns on execution tracing for this function; > > the flag -T does the same, but turns off tracing for any named (not > > anonymous) function called from the present one, unless that func‐ > > tion also has the -t or -T flag. > > > > makes it sound as if turning off for called functions is more > > powerful behaviour, in which case -T should always be used if > > specified. But it doesn't actually *say* that and could be > > rewritten anyway, so it's not much of a steer. Having one flag > > cause another to be ignored is pretty standard behaviour and > > relatively straightforward to implement, though. > > So, to be clear, you're proposing that setting either flag should unset > the other? Sounds good to me; just making sure we're on the same page. Actually, the suggestion was even simpler --- leave them both set, but just allow the -T behaviour to be used if both are set. I think this is how it's currently implemented, so it would just mean updating the documentation. However, actually unsetting the other one is entirely rational, too. Which is least surprising depends how you think of the options: whether you think of the option settings as strict alternatives, or you think of them as two separate options that happen to have an overlapping function of which you have to pick one. So I can't really express a preference, except to say if there's no good reason to change we should just document what we have. pws