Harald van Dijk <[email protected]> wrote: > On 16/01/2019 11:17, Geoff Clare wrote: > > It seems to me that the ksh behaviour here is rather undesirable, so > > maybe we should consider mandating (in Issue 8) that the last token in > > the value and the first token in the subsequent input must remain as > > separate tokens. > > If an alias ends in an unquoted backslash, then almost all shells do > combine it with the character following it: > > alias a='printf "<%s>\n" \' > a|cat > > prints > > <|cat> > > on almost all shells. The exceptions I can find are bash and zsh, which > print > > < > > > and pipe that through cat. > > None print <\> or <>, the two choices that shells pick for a backslash > not followed by anything else in other cases.
ksh88 prints <\cat> but the fact that even ksh93 also prints <|cat> is an argument against introducing a barrier between the alias replacement and the following text. 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/'
