zsh-workers
 help / color / mirror / code / Atom feed
From: Ricardo Giorni <ricardo@giorni.co>
To: zsh-workers@zsh.org
Subject: Re: [PATCH] fix backslash added incompatibility after previous patch
Date: Wed, 25 Apr 2018 09:09:03 -0300	[thread overview]
Message-ID: <90B0A319-7C3D-4E78-9F32-3F5EB1314910@giorni.co> (raw)
In-Reply-To: <B1EA1FD7-3E11-4365-892B-491DCE743C2E@giorni.co>

[-- Attachment #1: Type: text/plain, Size: 850 bytes --]

> On 22 Apr 2018, at 20:45, Ricardo Giorni <ricardo@giorni.co> wrote:
> 
> After patch 42355, escaped backslashes on here-documents stopped working.
> 
> 	cat <<-HERE
> 		foo\\
> 		bar
> 	HERE
> 
> Before patch 42355 (zsh 5.4), and on latest dash and bash:
> 
> 	foo\
> 	bar
> 
> After:
> 
> 	foo\	bar
> 
> —
> Ricardo

Adding more background here, after zsh-workers/42355, which updated the way here docs are processed, some open source configuration scripts that used to comment last backslash before new line broke.

What I did on this patch is move the comparison when a backslash is found, not when the new line is found. I added some new tests for this specific scenario.

What was changed on 42355 is still working, as the tests added at the time still shows up.

Can someone review it, please?

—
Ricardo


[-- Attachment #2: smime.p7s --]
[-- Type: application/pkcs7-signature, Size: 2894 bytes --]

  reply	other threads:[~2018-04-25 12:09 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-22 23:45 Ricardo Giorni
2018-04-25 12:09 ` Ricardo Giorni [this message]
2018-04-25 13:56   ` Bart Schaefer
2018-04-25 14:01     ` Peter Stephenson
2018-04-25 14:19       ` Bart Schaefer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=90B0A319-7C3D-4E78-9F32-3F5EB1314910@giorni.co \
    --to=ricardo@giorni.co \
    --cc=zsh-workers@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).