Re: Modified normalize_newlines to work on PC and Mac, too.

On 23.05.01 at 09:02, Martin Duerst <duerst@w3.org> wrote:

>I'm not sure the details in this mail are appropriate for this
>list, please just tell me if you get bored :-).

<voice type="pained">Please!</> If that's enough to bore people,
they would have lynched me a long time ago. :-)


>Start   Mac     PC      Unix
>CRLF    CR      CRCRLF  LF

ITYM

 CRLF    CR      CRLFCR  LF
                 ^^^^^^
non?


>LF      LF      LF      LF
         ^^
Oh darn! I /knew/ I hadn't got that one figured out properly. Good thing
the Validator doesn't run on Mac OS yet... :-)


>sub normalize_newlines {return [split /\015\012?|\012/, shift]};
>
>but once we are here, we might be able to get rid of the subroutine
>altogether.

I *like*! :-)

Received on Tuesday, 22 May 2001 21:05:45 UTC