Gustin Johnson wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Ralf Mardorf wrote:
>   
>>> http://www.google.ca/search?q=posix%20arrays
>>>   
>>>       
>> http://unix.derkeiler.com/Newsgroups/comp.unix.shell/2007-09/msg00320.html
>>
>> :)
>>     
> Did you read the reply?
> http://unix.derkeiler.com/Newsgroups/comp.unix.shell/2007-09/msg00322.html
>
> Here is an interesting bit from the first reply:
>
> If you want to claim that a piece of shell code is running on all
> POSIX conformant shells you have to restrict to the subset of features
> defined by POSIX.
>
> Limits on maximum array sizes are not even constant withing a specific
> shell. AFAIR, you can only rely on ~1000 on ksh88 while on ksh93 you
> have 4096 guaranteed (but the limit can be even higher depending on
> the version).
>
>     (or written for the "POSIX shell"), since another POSIX-compliant
>     shell might not implement arrays...?
>
>
> There's no *the* "POSIX shell". There's the POSIX standard and a
> couple of shells that support the features defined by the standard.

Hi Gustin :)

yes, that's why I added this link. It's something I read similar on 
German before. The POSIX standard doesn't know arrays, but even most sh 
(links) do know arrays. Arrays are common, but if somebody would be safe 
that his script will run on every shell he shouldn't use arrays, but it 
shouldn't be a problem to include arrays, because nearly every Linux 
install seem to support bash. Btw. by a German post it's written that 
Suse and Debian sh knows arrays too, Ubuntu seems to be an exception. 
Something I like. There should be a shell to test a script on POSIX 
standard only.

Taking a look at my Suse 11.1, sh is a link to bash, taking a look at my 
Suse 11.0, sh is a link to bash, taking a look at one of my 64 Studio 
2.1, sh is a link to bash. That seems to be the reason that nearly 
nobody was thinking about "sh filename" vs "./ filename", but you and I 
only found one post that mentioned to use variables in combination with 
"eval" instead of an array.

Today everybody simply use arrays. Good luck, by random I learned the 
"eval" alternative on POSIX standard and while learning I might stay on 
this.

Cheers,
Ralf
_______________________________________________
64studio-users mailing list
[email protected]
http://lists.64studio.com/mailman/listinfo/64studio-users

Reply via email to