Chet Ramey <chet.ra...@case.edu> wrote: > > But please explain (character by character) why you create an output that > > is in > > conflict with the reference implementation (a patched ksh88). > > `Character by character'? Really? > > (And obviously the so-called `reference implementation' doesn't reflect > the intent of the standard either, as revealed by the discussion.)
This claim does not match the general POSIX rules. > Anyway, bash, in its default mode, treats embedded single- and double- > quoted strings as special, and skips over them according to the "skipping > over enclosed quoted strings" portion of the text in 2.6.2 that's been > there since at least 1992. /usr/xpg4/bin/sh $ echo "${foo-'a"b'"}" > This is a certified POSIX shell.... and: ksh93 joerg@unknown:~/cmd$ echo "${foo-'a"b'"}" > behaves the same.... > In 2010-2011, I changed this -- when in Posix mode -- to not treat single > quotes as special, but to retain the existing treatment of embedded double- > quoted strings. This is valid even in the presence of issue 221, which > leaves the treatment of double quotes inside a double-quoted parameter > expansion as unspecified. Bash has never allowed double quotes inside a > parameter expansion to terminate a double-quoted string that begins > outside the expansion, so I wasn't going to start then. If this was the reason for Bourne derived behave diferent from bash, they would not print a PS2 prompt. Jörg -- EMail:jo...@schily.net (home) Jörg Schilling D-13353 Berlin joerg.schill...@fokus.fraunhofer.de (work) Blog: http://schily.blogspot.com/ URL: http://cdrecord.org/private/ http://sourceforge.net/projects/schilytools/files/'