develooper Front page | perl.perl5.porters | Postings from August 2012

[perl #65838] heredoc terminators need a newline

Thread Next
From:
Father Chrysostomos via RT
Date:
August 21, 2012 14:35
Subject:
[perl #65838] heredoc terminators need a newline
Message ID:
rt-3.6.HEAD-11172-1345584900-1154.65838-15-0@perl.org

On Wed Jun 17 22:44:34 2009, davidnicol@gmail.com wrote:
> Revised patch

Thank you.  I tried applying this, but other changes in the mean time
stopped it from working.  While I was working on it, I realised that it
would actually be simpler to tack \n on the end of the input buffer at
EOF, instead of backtracking on error.  So I did that in commit 112d128413.

The rest of the patch a broke up into little bits, partly to preserve
correct attribution, and partly to keep commit messages accurate.

Your tests (without Schwern’s changes) I applied as c8e9f72fa0.

> striking all but one proposed trailblaze kinds of
> comments from patch to toke.c,

Your one remaining comment (about <<\FOO) I applied as 458391bde9.

> including Schwern's revision of
> heredoc.t and patch to test.pl to make them behave better,

Applied as c49688b0187.

> and
> striking the passage from perlop.pod warning against heredocs running
> off the end of the file without a final newline

f35fca8637

> (the resolution of
> http://rt.perl.org/rt3/Ticket/Display.html?id=30368 five years ago)
> and also a touch of rewriting perlop.pod's section on heredocs,
> including mentioning the \STRING syntax

Tom Christiansen has already documented that in the mean time.

> (which has worked since when?
> Perl 1.0? )

3.0

> and revising the section about embedded heredocs in the
> second half of a s///e so it might make sense faster.

That part I didn’t apply, since I was going to modify that section of
the document anyway, as it wasn’t true.

-- 

Father Chrysostomos


---
via perlbug:  queue: perl5 status: open
https://rt.perl.org:443/rt3/Ticket/Display.html?id=65838

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About