develooper Front page | perl.perl5.porters | Postings from July 2004

Perl cannot cope with mixed LineEnds (bug IMHO)

Thread Next
From:
Richard Jelinek
Date:
July 30, 2004 01:52
Subject:
Perl cannot cope with mixed LineEnds (bug IMHO)
Message ID:
20040729231153.A16115@petamem.com
Hi there.

We are living with a restriction of Perl that is becoming more and
more a nuisance:

In UTF-8 encoding, CRLF and LF (and probably CR only) are valid
markers for a line-end. We use Emacs for editing - especially the
module folding.el, that is able to do hierarchical folding.

folding.el basically achives the folding by putting a different
line-end code after the folding mark. I guess CRLF instead of just
LF but don't know that exactly now.

Well folding is great and we are used to it. Unfortunatedly, this only works,
if the perl source code is kept in ISO-8859 encoding. As soon as the
source code is UTF-8, folding.el still works like a charm, but Perl
won't. It simply doesn't see the folded sections anymore.

Seems the tokenizer/parser of perl ignores/oversees lines that are
after such an alternate line-end code.

We have tried this with up to 5.8.x with the same - negative -
result. Is there any chance, that the Perl tokenizer/parser can be
modified to be able to cope with that sort of input files?

-- 
best regards,

     Dipl.-Inf. Richard Jelinek

     - The PetaMem Group - Prague/Nuremberg - www.petamem.com -
		       -= 3394928 Mind Units =-

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