Bruno Haible wrote: > Eric Blake wrote: >>> This looks like a bug to me: \\ expands to nothing. No way to produce a >>> backslash in the replacement. >> I concur. > > Thanks. So I'm disabling --posix. Patch appended. > >> "... For each other <backslash> encountered, the following >> character shall lose its special meaning (if any). The meaning of a >> <backslash> >> immediately followed by any character other than ’&’, <backslash>, a digit, >> or >> the delimiter character used for this command, is unspecified." >> >> Thus, 's,^,\/,', is non-portable. > > Thanks for explaining. So the third of the mentioned sed expressions is not > POSIX compliant. Fixing it, as attached.
FWIW, the bug mentioned earlier in the thread is already fixed in git sed. Paolo
