[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Escaped newlines with %q format specifier
- From: Coda Highland <chighland@...>
- Date: Wed, 2 Jul 2014 11:36:04 -0700
On Wed, Jul 2, 2014 at 11:05 AM, Steven Degutis <firstname.lastname@example.org> wrote:
> I would have to agree, the \newline behavior is definitely surprising
> to me and not intuitive. I would expect that \newline is completely
> ignored, and \n is the only way to represent a newline.
While I agree that it's surprising, I wouldn't ask the behavior to
change. It's internally consistent -- all escaped characters are
preserved literally unless they belong to a predefined set of escape
sequences, which is a desirable trait -- and there's no reason to
change the behavior for existing scripts.
Nothing wrong with being different from C.