Subject: Re: Re: [ksh93-integration-discuss] printf syntax and /sbin/shcompatibility --------
> I tend to agree; I just think it would be helpful if a page was put up > on the ksh93 integration project page that detailed what the approach > and plan is to deal with bugs, incompatibilities, etc. > > Here is my view on this. It is important to comply to the standard. Anyone who writes a strictly conforming script should be able to run it without change with ksh93. If we believe that the standard is in error, we will bring up the issue to the Austin group and wait for an interpretation and then do what is necessary to conform. If a script is non-conforming, we try to extend the bahavior of commands to match historical implementations so that as many non-conforming scripts can continue to run as possible. As cases arise, we tend to make changes that do not violate the standard to allow non-conforming scripts to run. In these case of printf, the standard clearly requires that -- be treated as end of options argument so we have to do this. In the case of ---------------, the standard refers to this as an option. Since we don't recognized this option we currently report this as an error as required. However, if we extend printf by stating that all options beginning with --- are recognized and treated as if it is an operand, then we would still conform to the standard and also allow more non-conforming scripts to continue to run. The standard allows implementations to accept options not reserved by the standard. Our plan is to modify the options parser so that all options beginning with --- are treated as if they were operands rather than options. Note, that this will not allow all non-conforming scripts to work, for example printf --foobar will produce an error since --foobar is an unrecognized option and we want to preserve the --* space for future extensions. David Korn dgk at research.att.com