[phobos] The time has come to destroy all y'all over CR/LF

Andrei Alexandrescu andrei at erdani.com
Wed Jan 26 12:03:41 PST 2011


On 1/26/11 1:18 PM, Walter Bright wrote:
>
>
> Andrei Alexandrescu wrote:
>>
>> So CR alone should be available as "go to the beginning of the current
>> line". LF alone should mean "go to the beginning of the next line".
>> And that should be it. Unix got this right. CP/M et al got this wrong.
>>
>
> CP/M did not invent that meaning for LF. LF goes back decades earlier
> than CP/M.

I mentioned CP/M because it's the first OS that inherited the sequence 
without actually being backed up by a paper-based TTY, where a very weak 
argument could be constructed that CR/LF is how the mechanics of the 
system works.

> In the early 80's, unix wasn't seen much. The best systems were the DEC
> computers, and a lot of software professionals expected DEC to become
> the dominant player. DEC operating systems were widely seen as the best.
> (IBM was still mired in their ridiculous EBCDIC encoding.)
>
> I suspect that unix and its conventions would be dead by now if not for
> Linux.

Be that as it may, in Unix '\n' means "go to the beginning of next line" 
and '\r' means "go to the beginning of the current line". I argued 
destructively that this is the way things should have been EVEN on 
paper-based terminals and NO DISCUSSION the way things should be on 
today's terminal emulators.

Unix got this right. CP/M et al got this wrong.


Andrei


More information about the phobos mailing list