zsh-workers
 help / color / mirror / code / Atom feed
From: "Bart Schaefer" <schaefer@brasslantern.com>
To: zsh-workers@sunsite.auc.dk
Subject: Re: quote modifier for parameter expansion?
Date: Wed, 3 Feb 1999 09:20:55 -0800	[thread overview]
Message-ID: <990203092055.ZM11946@candle.brasslantern.com> (raw)
In-Reply-To: <9902031602.AA40342@ibmth.df.unipi.it>

On Feb 3,  5:02pm, Peter Stephenson wrote:
} Subject: Re: quote modifier for parameter expansion?
}
} Sven Wischnowsky wrote:
} > Hm. I'm sure I'm missing something again, but could anyone please tell 
} > me what? The patch below (which probably shouldn't be used) just uses
} > the quote()-function from hist.c to make the `q' modifier in parameter 
} > expansion work.
} 
} % bar="hello'there"
} % print -r $bar:q
} 'hello'\''there'
} 
} Maybe the point is simply it's got limited application, since unless
} it's going into an eval the extra quotes aren't all that useful,

Maybe the point is that :q is a csh-ism, and that result is nothing like
what csh would produce.

In the old days before people worried about 8-bit characters, :q in csh
simply set the high-order bit of every character in the variable value.
Then those high bits would get stripped off again after all the other
substitutions were applied.  Thus there was no user-visible change to
the string.

That doesn't make it useless, but if we keep it, it belongs in the
section on differences from (t)csh.

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com


  reply	other threads:[~1999-02-03 17:20 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-02-03 15:52 Sven Wischnowsky
1999-02-03 16:02 ` Peter Stephenson
1999-02-03 17:20   ` Bart Schaefer [this message]
1999-02-03 16:28 Sven Wischnowsky
1999-02-05  8:50 Sven Wischnowsky

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=990203092055.ZM11946@candle.brasslantern.com \
    --to=schaefer@brasslantern.com \
    --cc=zsh-workers@sunsite.auc.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).