zsh-workers
 help / color / mirror / code / Atom feed
From: martin f krafft <madduck@debian.org>
To: 526924@bugs.debian.org, zsh-workers@sunsite.dk
Subject: Re: Bug#526924: zparseopts: should use lists as values in assoc array
Date: Tue, 5 May 2009 18:36:35 +0200	[thread overview]
Message-ID: <20090505163635.GC2608@piper.oerlikon.madduck.net> (raw)
In-Reply-To: <20090505160528.GB19068@scru.org>

[-- Attachment #1: Type: text/plain, Size: 876 bytes --]

also sprach Clint Adams <schizo@debian.org> [2009.05.05.1805 +0200]:
> Unfortunately we don't handle arrays as values of associate arrays
> (yet?) but you can do something like

Aha.

pulse:~|master|% declare -A foo; foo[Clint]=(1 2 3)
zsh: foo: attempt to set slice of associative array

:(

> set -- -a1 -a2; zparseopts 'a+:=arr'; print -l $arr
> 
> although this seems to set arr=(1 -a 2), which is not what I
> expected to happen.

Yeah, that's a bit weird, isn't it? Should I clone the bug?

As for the original bug, maybe just insering $IFS[0] between
elements would do?

-- 
 .''`.   martin f. krafft <madduck@d.o>      Related projects:
: :'  :  proud Debian developer               http://debiansystem.info
`. `'`   http://people.debian.org/~madduck    http://vcs-pkg.org
  `-  Debian - when you have better things to do than fixing systems

[-- Attachment #2: Digital signature (see http://martin-krafft.net/gpg/) --]
[-- Type: application/pgp-signature, Size: 197 bytes --]

  reply	other threads:[~2009-05-05 16:37 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20090504130124.GA13947@piper.oerlikon.madduck.net>
2009-05-05 16:05 ` Clint Adams
2009-05-05 16:36   ` martin f krafft [this message]
2009-05-05 17:05   ` Bart Schaefer
2009-05-05 17:28     ` martin f krafft

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=20090505163635.GC2608@piper.oerlikon.madduck.net \
    --to=madduck@debian.org \
    --cc=526924@bugs.debian.org \
    --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).