zsh-workers
 help / color / mirror / code / Atom feed
From: Tanaka Akira <akr@jaist.ac.jp>
To: zsh-workers@sunsite.auc.dk
Subject: Re: PATCH: new parameter expansion type?
Date: 30 Aug 1999 19:58:56 +0900	[thread overview]
Message-ID: <rsqzoz9a61b.fsf@crane.jaist.ac.jp> (raw)
In-Reply-To: Sven Wischnowsky's message of "Mon, 30 Aug 1999 11:49:27 +0200 (MET DST)"

In article <199908300949.LAA20865@beta.informatik.hu-berlin.de>,
  Sven Wischnowsky <wischnow@informatik.hu-berlin.de> writes:

> --- od/Zsh/expn.yo	Sun Aug 29 20:02:39 1999
> +++ Doc/Zsh/expn.yo	Sun Aug 29 22:00:54 1999
> @@ -447,6 +447,21 @@
>  while in the second case, the shortest matches are taken and the
>  result is `tt(spy spy lispy star)'.
>  )
> +xitem(tt(${)var(name)tt(^)var(pattern)tt(^)var(then)tt(^)var(else)tt(}))
> +item(tt(${)var(name)tt(^^)var(pattern)tt(^)var(then)tt(^)var(else)tt(}))(
> +If the expansion of var(name) matches the var(pattern), the var(then)
> +string is substituted, otherwise the var(else) string is
> +substituted. In the second form the var(pattern) is taken to be
> +negated (even if the tt(EXTENDED_GLOB) option is not set. The
> +var(else) string with the preceding `tt(^)' may be omitted in which
> +case the expansion behaves as if var(name) were unset (or, if
> +var(name) is an array, as if the element compared did not exist). In
> +the var(pattern) and the var(then) string a `tt(^)' may be included by 
> +preceding it with two backslashes. Finally, the var(then) and
> +var(else) string may consist of only a dot to make it expand to the
> +original string. To make them expand to only a dot, the string
> +`tt(\.)' has to be used.
> +)
>  item(tt(${#)var(spec)tt(}))(
>  If var(spec) is one of the above substitutions, substitute
>  the length in characters of the result instead of

Hm. Parentheses doesn't match.

Index: Doc/Zsh/expn.yo
===================================================================
RCS file: /projects/zsh/zsh/Doc/Zsh/expn.yo,v
retrieving revision 1.1.1.25
diff -u -F^( -r1.1.1.25 expn.yo
--- expn.yo	1999/08/30 10:17:30	1.1.1.25
+++ expn.yo	1999/08/30 10:35:44
@@ -452,7 +452,7 @@ (This and the following
 If the expansion of var(name) matches the var(pattern), the var(then)
 string is substituted, otherwise the var(else) string is
 substituted. In the second form the var(pattern) is taken to be
-negated (even if the tt(EXTENDED_GLOB) option is not set. The
+negated (even if the tt(EXTENDED_GLOB) option is not set). The
 var(else) string with the preceding `tt(^)' may be omitted in which
 case the expansion behaves as if var(name) were unset (or, if
 var(name) is an array, as if the element compared did not exist). In
-- 
Tanaka Akira


  parent reply	other threads:[~1999-08-30 14:59 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-08-30  9:49 Sven Wischnowsky
1999-08-30 10:06 ` Andrej Borsenkow
1999-08-30 10:58 ` Tanaka Akira [this message]
1999-08-30 16:05 ` Bart Schaefer
1999-08-30 16:10   ` Peter Stephenson
1999-08-30 10:38 Sven Wischnowsky
1999-08-31 13:18 ` Andrej Borsenkow
1999-08-31  8:50 Sven Wischnowsky
1999-08-31 17:47 ` Bart Schaefer

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=rsqzoz9a61b.fsf@crane.jaist.ac.jp \
    --to=akr@jaist.ac.jp \
    --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).