From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8599 invoked by alias); 12 Sep 2016 23:07:31 -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: 39300 Received: (qmail 11578 invoked from network); 12 Sep 2016 23:07:31 -0000 X-Qmail-Scanner-Diagnostics: from out4-smtp.messagingengine.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(66.111.4.28):SA:0(0.0/5.0):. Processed in 0.526945 secs); 12 Sep 2016 23:07:31 -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=T_DKIM_INVALID autolearn=unavailable autolearn_force=no version=3.4.1 X-Envelope-From: d.s@daniel.shahaf.name X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | Received-SPF: none (ns1.primenet.com.au: domain at daniel.shahaf.name does not designate permitted sender hosts) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= daniel.shahaf.name; h=content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-sasl-enc:x-sasl-enc; s=mesmtp; bh=xdrEtVsdZWWvdFDe pLMDGgvVXbU=; b=aBkuNbWbswPbZGwhHpqu0u2FgvSDyx49P29cqSR0kcRdizec M7f6zRC9DIPjfyyBRKNnz8GTBHGl1hIXgz+Af0bOXLhz0iGZciVsBsL6bWb50EoL wGZNGwjaNlxrXk6gQ44BDNcnb6N0pLfDPwiqVHrFa97yDHs8kpLUqAFOyO8= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-sasl-enc:x-sasl-enc; s=smtpout; bh=xdrEtVsdZWWvdFD epLMDGgvVXbU=; b=CZ1zOsZAE8SJciXnjmUTO7mlwyxzYttHK7tDwVkOiXW0Zbz y51KxYeF6Un9ji38SLzlKCx3NPzFHJpDOnhB3c4QrA1eGXpjC9gQnzZY+fjaaNAo 6bExdweKoMmOGxYkkg+M4EnYphtKoF8I2gb3fke3zqjl6AJd7zE9EveTkHk0= X-Sasl-enc: LBeufWgkW4oiQeICGw5t9HS7MS81iEBcEb6k3u8p6IZs 1473721641 Date: Mon, 12 Sep 2016 23:06:32 +0000 From: Daniel Shahaf To: zsh-workers@zsh.org Subject: Re: compset -q oddities Message-ID: <20160912230632.GA29577@fujitsu.shahaf.local2> References: <20160911073031.GA19137@fujitsu.shahaf.local2> <160911191422.ZM21970@torch.brasslantern.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <160911191422.ZM21970@torch.brasslantern.com> User-Agent: Mutt/1.5.23 (2014-03-12) Bart Schaefer wrote on Sun, Sep 11, 2016 at 19:14:22 -0700: > On Sep 11, 7:30am, Daniel Shahaf wrote: > } > } I managed to break a few things while composing a reply to 39265: > > I think mostly what you've discovered is cases where "compset" is not > compensating for pilot error. "compset -q" does not expect to be > called on an empty word, or on any word that can't be interpreted as > a (possibly partial) command line; Thanks, but I don't understand how any of those examples constitutes a "pilot error" or an empty word. In #1, "~~~" is a complete word; completion changed it to "~~~~~~" which is also a complete word but wasn't a candidate completion. In #2 and #3, the input is a prefix of a valid command line («g $'\'foo\''» and «h "$'foo'"» respectively). #2 does not involve an empty word; the word there is «'» (a single-byte word). Thanks again for the explanation. I'd like to understand what the expected behaviour here is. They triggered DPUTS calls so I assumed they were bugs. Cheers, Daniel (#2 doesn't call compadd, but behaves the same if a call to _nothing is added to _g.)