bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Feature Request: scanf-like parsing


From: Oğuz
Subject: Re: Feature Request: scanf-like parsing
Date: Mon, 25 Jan 2021 18:47:36 +0200

25 Ocak 2021 Pazartesi tarihinde Chet Ramey <chet.ramey@case.edu> yazdı:
>
> There has been code to do this for a long time. It's currently tagged for
> bash-5.2. If you want to play around with it, look in subst.c for
> shouldexp_replacement and its caller, and uncomment them. You'll have to
> wait for the next devel branch push for a version that works with multibyte
> characters -- that should tell you how long it's been there.
>

Great, thanks!

25 Ocak 2021 Pazartesi tarihinde Chet Ramey <chet.ramey@case.edu> yazdı:
>
> I forgot to mention that since the keys and values are both quoted so they
> can be reused, you can copy an associative array using a key-value
> assignment like
>
> declare -A copy
> eval copy=( "${assoc[@]@K}" )


So many reputable people contributed to the demonization of `eval' that I
don't think I can convince anyone that there's nothing wrong with it
anymore.


-- 
Oğuz


reply via email to

[Prev in Thread] Current Thread [Next in Thread]