Harald van Dijk <[email protected]> wrote:

> On 14/01/2019 13:32, Joerg Schilling wrote:
> > posh does not work on platforms with a POSIX compliant getopt(), so there 
> > are
> > other reasons not to take posh into account.
>
> This is misleading. There are platforms with a POSIX compliant getopt() 
> on which it does not work, but there are also platforms with a POSIX 
> compliant getopt() on which it does work. Almost all shells, if not all, 
> rely on extensions and/or make some not-100%-portable assumptions. That 
> is not a good reason to disregard them.

But code that does not work on (some) POSIX compliant platforms is not POSIX 
compliant as it is in conflict with the POSIX rules.

posh does not work because it sets "optind" to 0 even though POSIX requires it 
to be initialized with 1.

Jörg

-- 
 EMail:[email protected]                    (home) Jörg Schilling D-13353 Berlin
    [email protected] (work) Blog: http://schily.blogspot.com/
 URL: http://cdrecord.org/private/ http://sf.net/projects/schilytools/files/'

Reply via email to