zsh-users
 help / color / mirror / code / Atom feed
From: Borsenkow Andrej <Andrej.Borsenkow@mow.siemens.ru>
To: martin.ebourne@arcordia.com, zsh-users@sunsite.dk
Subject: RE: Zsh Guide chapter 5 (substitutions)
Date: Thu, 23 Aug 2001 11:30:10 +0400	[thread overview]
Message-ID: <007301c12ba5$70b84fd0$21c9ca95@mow.siemens.ru> (raw)
In-Reply-To: <OF29CEBB17.CA244083-ON80256AB0.005C733C@uk.jpmorgan.com>

> 
> I don't know if anyone has already pointed this out, but in the user
guide
> section 5.4.2:
> 
>   perl                          zsh
>   -----------------------------------------------------------------
>   %hash2 = %hash;               typeset -A hash2; hash2=(${(kv)hash})
> 
> Surely this should be hash2=("${(@kv)hash}") in case of empty string
> values.
> 


No (at least, if running as zsh):

bor@itsrm2% foo=(a "a a" b "b b")
bor@itsrm2% print -l $foo
a a
b b
bor@itsrm2% typeset -A bar
bor@itsrm2% bar=(${(kv)foo})
bor@itsrm2% print -l $bar   
a a
b b

-andrej


  reply	other threads:[~2001-08-23  7:30 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-08-22 17:10 martin.ebourne
2001-08-23  7:30 ` Borsenkow Andrej [this message]
2001-08-23  7:41   ` Borsenkow Andrej
  -- strict thread matches above, loose matches on Subject: below --
2001-08-15 23:00 Peter Stephenson
2001-08-16  2:31 ` Bart Schaefer
2001-08-17 16:55 ` Bart Schaefer
2001-08-20 18:26 ` Bart Schaefer
2001-08-20 18:35   ` Phil Pennock
2001-08-21 16:38   ` Bart Schaefer
2001-08-21 14:21 ` Richard Curnow
2001-08-21 15:34   ` 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='007301c12ba5$70b84fd0$21c9ca95@mow.siemens.ru' \
    --to=andrej.borsenkow@mow.siemens.ru \
    --cc=martin.ebourne@arcordia.com \
    --cc=zsh-users@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).