Re: [PATCH v2] expand: Do not quote backslashes in unquoted parameter expansion

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 3/29/18 6:42 AM, Herbert Xu wrote:
On Wed, Mar 28, 2018 at 03:06:32PM +0200, Harald van Dijk wrote:

Since bash itself is inconsistent, and POSIX unclear,
What exactly is unclear about the sentence of POSIX that I quoted? Is there
a legitimate interpretation of "It is unspecified whether A or B" that
allows other behaviour than A or B?

The tricky part is coming up with a way to actually produce an
unescaped backslash.

You're right that what other shells implement doesn't allow any possibility of unescaped backslashes in the shell. But if what they do is what's intended, the sentence still makes perfect sense to me: it simply wouldn't affect the shell. Remember that the description of pattern matching applies to both the shell and the non-shell cases. For the non-shell cases, it's trivial, and it's possible that that was all it was intended to address:

  find . -name 'a\'

Cheers,
Harald van Dijk
--
To unsubscribe from this list: send the line "unsubscribe dash" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [LARTC]     [Bugtraq]     [Yosemite Forum]     [Photo]

  Powered by Linux