bug-bash
[Top][All Lists]
Advanced

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

Re: Any chance of multi-dimensional arrays?


From: Eduardo Bustamante
Subject: Re: Any chance of multi-dimensional arrays?
Date: Sun, 25 Nov 2012 21:51:03 -0800

Hey, calm down. People are just trying to help.

Also, this question has already been asked previously. Please read this:

http://lists.gnu.org/archive/html/bug-bash/2011-09/msg00062.html

(To put you in context, Chet Ramey is the current maintainer of bash).

It's not really an important feature. Bash is already doing too much for a
*shell* language (yes, note that a shell language isn't the same as a
scripting language).

There are a lot of general purpose languages (not shell languages), that
support multi-dimensional arrays. And these languages can call external
tools just fine. Python, Perl, Ruby, ... pick one. Even Awk has faked
support for multi-dimensional arrays.

Don't take me wrong though. Bash is really good, for what it was meant. If
you need complex data structures, or complex text processing, bash isn't
really the best tool for the job.

Just do yourself a favor, and start learning a new language. One that
supports custom data structures. That already has support for
multi-dimensional arrays.


P.S.: If you still have problems understanding the difference between a
shell, and a general purpose language:
http://en.wikipedia.org/wiki/Shell_(computing)#Text_.28CLI.29_shells

--
Eduardo Bustamante





On Sun, Nov 25, 2012 at 9:32 PM, Rene Herman <rene.herman@gmail.com> wrote:

> On 11/25/2012 08:54 PM, Bob Proulx wrote:
>
>  There are various naming conventions and schemes to simulate
>> multi-dimensional arrays using single dimension arrays.  Since you
>> want to continue with the shell and the shell has not (yet) provided
>> multi-dimensional arrays then the only option for you is to simulate
>> them. That isn't too difficult and if you search the web there are
>> many different implementations with the biggest difference being
>> whether ordering matters or not.
>>
>
> Yes. However, that was not my question, as was also the case for the
> previous reply. I already indicated in the original posting that I'm aware
> of work-arounds. Here it is again:
>
> http://lists.gnu.org/archive/**html/bug-bash/2012-11/**msg00048.html<http://lists.gnu.org/archive/html/bug-bash/2012-11/msg00048.html>
>
> The question, to the bash developers (<-- !) is simply if there are any
> plans for implementing multi-dimensional array support, with the two
> implied statements being that a) I'd like that and b) I have a fairly
> non-contrived use-case for them, which I thought might be welcome as an
> argument.
>
> It's been a long time since I participated on open-source mailing-lists
> and I'm remembering why. Please don't take it the wrong way, but please,
> pretty please, unless you can answer the question, just don't bother
> replying.
>
> Rene.
>
>


reply via email to

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