zsh-workers
 help / color / mirror / code / Atom feed
From: Peter Stephenson <p.w.stephenson@ntlworld.com>
To: Zsh hackers list <zsh-workers@sunsite.dk>
Subject: Re: vared 'functions[xx]'
Date: Thu, 13 Dec 2007 21:23:48 +0000	[thread overview]
Message-ID: <20071213212348.80912b31.p.w.stephenson@ntlworld.com> (raw)
In-Reply-To: <chaz20071213172705.GB24933@artesyncp.com>

On Thu, 13 Dec 2007 17:27:07 +0000
Stephane Chazelas <stephane_chazelas@yahoo.fr> wrote:
> I had an odd behavior here.
> 
> ~$ a() echo foo
> ~$ vared functions\[a\]\
> 
> Above, the trailing "\ " was added by the completion system.

This stops that happening.  I think it's fine in that we certainly need
one level less of quoting to the space than to the square brackets.
However, if there are multiple levels of quoting involved it gets
hairier.  That's probably not a problem in practice.

I'll see if there's something funny in vared separately.

Index: Completion/Zsh/Context/_subscript
===================================================================
RCS file: /cvsroot/zsh/zsh/Completion/Zsh/Context/_subscript,v
retrieving revision 1.11
diff -u -r1.11 _subscript
--- Completion/Zsh/Context/_subscript	16 Apr 2002 07:48:46 -0000	1.11
+++ Completion/Zsh/Context/_subscript	13 Dec 2007 21:22:23 -0000
@@ -3,8 +3,8 @@
 local expl ind osuf=']' flags sep
 
 if [[ "$1" = -q ]]; then
-  osuf='] '
   compquote osuf
+  osuf+=' '
   shift
 fi
 

-- 
Peter Stephenson <p.w.stephenson@ntlworld.com>
Web page now at http://homepage.ntlworld.com/p.w.stephenson/


  reply	other threads:[~2007-12-13 21:25 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-13 17:27 Stephane Chazelas
2007-12-13 21:23 ` Peter Stephenson [this message]
2007-12-13 21:41 ` Peter Stephenson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20071213212348.80912b31.p.w.stephenson@ntlworld.com \
    --to=p.w.stephenson@ntlworld.com \
    --cc=zsh-workers@sunsite.dk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).