January 26, 2011 [phobos] The time has come to destroy all y'all over CR/LF | ||||
---|---|---|---|---|
| ||||
Posted in reply to Don Clugston | Vote++. No end user of any production quality program should ever have to care about such trivia as line terminators except in extreme corner cases (like the aforementioned case of ending up w/ a CR LF that come from two different edits on two different OS's). On Wed, Jan 26, 2011 at 3:47 PM, Don Clugston <dclugston at googlemail.com>wrote: > On 26 January 2011 20:37, David Simcha <dsimcha at gmail.com> wrote: > > Forgive my ignorance, but why is this such a big issue? Shouldn't any decent programmer tool (diff utility, editor, IDE, etc.) be able to interpret CR, LF and CR LF as effectively meaning the same thing and do > what > > you mean? > > The thing Microsoft should be shot for, is for continuing to provide a default text editor (Notepad) which can't handle LF as an end-of-line marker. That's inexcusable. > > How many end-of-lines are in "\n\r\n\n\r" ? Notepad says 1. > _______________________________________________ > phobos mailing list > phobos at puremagic.com > http://lists.puremagic.com/mailman/listinfo/phobos > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.puremagic.com/pipermail/phobos/attachments/20110126/15800327/attachment.html> |
January 26, 2011 [phobos] The time has come to destroy all y'all over CR/LF | ||||
---|---|---|---|---|
| ||||
Posted in reply to David Simcha |
David Simcha wrote:
> Forgive my ignorance, but why is this such a big issue? Shouldn't any decent programmer tool (diff utility, editor, IDE, etc.) be able to interpret CR, LF and CR LF as effectively meaning the same thing and do what you mean? In the context of source code noone ever wants to go to the beginning of the current line. The only time it can become ambiguous is when a CR LF was actually produced by two different edits with different settings (and is therefore supposed to mean two newlines, not one) and even then it only mildly screws up the whitespace.
>
> Bottom line: I fail to see why different line endings should be such an issue in the first place, unless we're using some overly strict or Stone Age tool that favors absolute adherence to some specification over common sense. In such cases it's more the tool that's the problem, not the source file. I don't give a hoot which line ending anyone uses, because all my tools seem to "just work" regardless, and I have absolutely no clue what line ending my IDE is set up to use because I don't understand why it really matters in practice.
>
Good question. In all the software I've written, I've gone to some effort to ensure that line endings of LF, CRLF, and CR are automatically taken care of. I've been doing this for 30 years.
Why text processing programs on both sides of the fence *still* fail at this is beyond comprehension:
1. Windows Notepad
2. meld
3. many diff programs
4. git
5. FreeBSD make
|
January 26, 2011 [phobos] The time has come to destroy all y'all over CR/LF | ||||
---|---|---|---|---|
| ||||
Posted in reply to David Simcha |
David Simcha wrote:
> Vote++. No end user of any production quality program should ever have to care about such trivia as line terminators except in extreme corner cases (like the aforementioned case of ending up w/ a CR LF that come from two different edits on two different OS's).
>
That's still NOT a problem. Merely treat each line as unique. Look at dmd's lexer.c to see how it's done. It's trivial.
|
January 26, 2011 [phobos] The time has come to destroy all y'all over CR/LF | ||||
---|---|---|---|---|
| ||||
Posted in reply to Andrei Alexandrescu | Andrei Alexandrescu wrote: > 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. Are you sure that ASR-33's, DECwriters, Daisy wheels, and glass terminals were not used with CP/M? They were! > >> 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. > I agree that the Unix way is better. But it is not *wrong* to be compatible with the enormous inertia of existing practice. (CP/M worked like RT-11, and RSTS-11, which were enormously successful minicomputer systems. I have always been amused by the charges that Microsoft "stole" ideas from CP/M with no mention that CP/M was a copy of DEC's systems.) |
January 27, 2011 [phobos] The time has come to destroy all y'all over CR/LF | ||||
---|---|---|---|---|
| ||||
Posted in reply to Walter Bright | On 01/26/2011 08: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. > > In the early 80's, unix wasn't seen much. Yop, even HP-UX was introduced only in the mid-80's: http://en.wikipedia.org/wiki/HP-UX > 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. A // history of computing ;-) (I dream a more user-friendly [instead of sysadmin-friendly] filesystem hierarchy had won the game.) Denis -- _________________ vita es estrany spir.wikidot.com |
January 27, 2011 [phobos] The time has come to destroy all y'all over CR/LF | ||||
---|---|---|---|---|
| ||||
Posted in reply to Walter Bright | On 01/26/2011 10:53 PM, Walter Bright wrote: > > > David Simcha wrote: >> Forgive my ignorance, but why is this such a big issue? Shouldn't any decent programmer tool (diff utility, editor, IDE, etc.) be able to interpret CR, LF and CR LF as effectively meaning the same thing and do what you mean? In the context of source code noone ever wants to go to the beginning of the current line. The only time it can become ambiguous is when a CR LF was actually produced by two different edits with different settings (and is therefore supposed to mean two newlines, not one) and even then it only mildly screws up the whitespace. >> >> Bottom line: I fail to see why different line endings should be such an issue in the first place, unless we're using some overly strict or Stone Age tool that favors absolute adherence to some specification over common sense. In such cases it's more the tool that's the problem, not the source file. I don't give a hoot which line ending anyone uses, because all my tools seem to "just work" regardless, and I have absolutely no clue what line ending my IDE is set up to use because I don't understand why it really matters in practice. >> > > Good question. In all the software I've written, I've gone to some effort to ensure that line endings of LF, CRLF, and CR are automatically taken care of. I've been doing this for 30 years. > > Why text processing programs on both sides of the fence *still* fail at this is beyond comprehension: > > 1. Windows Notepad > 2. meld > 3. many diff programs > 4. git > 5. FreeBSD make Indeed it's trivial (convert on input every line ending to a unique form that could be at best unicode <LINE SEPARATOR> not to be accused of bias ;-), then convert back to the current Os's form on output). Tons of PLs do that transparently. I also cannot understand why any tool in the XXIth century does not provide this feature (without even mentioning it, so trivial an issue it is). Even less /programmer/ tools like git! Where's the point? Denis -- _________________ vita es estrany spir.wikidot.com |
January 26, 2011 [phobos] svn-->git migration | ||||
---|---|---|---|---|
| ||||
Posted in reply to Brad Roberts | Ok, I realize I'm not exactly on the ball here, but I just created my github acct. w/ username dsimcha. Please add me, as I now have stuff to commit.
On 1/23/2011 4:30 PM, Brad Roberts wrote:
> On 1/23/2011 1:12 PM, Jason Evans wrote:
>> I converted the druntime repository from svn to git a few days ago, and I'm doing the same for phobos and dmd today. Please hold any pending changes you have until the conversion is complete, then commit your changes to the git repository. See https://github.com/D-Programming-Language for more information about the git repositories.
>>
>> For right now I'm focusing on getting the conversion done as quickly and smoothly as possible, but after it's done, I'll try to help people with general git configuration and work flow issues as necessary.
>>
>> Thanks,
>> Jason
> As part of this migration, I've gone ahead and removed permission to the dsource project from (almost) everyone to avoid accidental submits. So, for the moment, we're in a minor limbo state, but hold tight.
>
> If we need to roll back, I'll add everyone back in. In the mean time, for those of you without github accounts, go create one. Please send your github user id's so that we can add you to the appropriate permissions set to be able to push changes into the phobos repository.
>
> Thanks,
> Brad
> _______________________________________________
> phobos mailing list
> phobos at puremagic.com
> http://lists.puremagic.com/mailman/listinfo/phobos
>
|
January 30, 2011 [phobos] svn-->git migration | ||||
---|---|---|---|---|
| ||||
Posted in reply to Jason Evans | On 1/23/2011 1:12 PM, Jason Evans wrote:
> I converted the druntime repository from svn to git a few days ago, and I'm doing the same for phobos and dmd today. Please hold any pending changes you have until the conversion is complete, then commit your changes to the git repository. See https://github.com/D-Programming-Language for more information about the git repositories.
>
> For right now I'm focusing on getting the conversion done as quickly and smoothly as possible, but after it's done, I'll try to help people with general git configuration and work flow issues as necessary.
>
> Thanks,
> Jason
> _______________________________________________
> phobos mailing list
> phobos at puremagic.com
> http://lists.puremagic.com/mailman/listinfo/phobos
>
Seems I'm a bit out of the loop. What is the extent of the migration? Is the dsource SVN server being decommissioned and the rest of the projects being evicted/transplanted or is it just the ones that have already been moved? (FWIW, I don't use GIT and would rather not have to.)
|
January 30, 2011 [phobos] svn-->git migration | ||||
---|---|---|---|---|
| ||||
Posted in reply to Benjamin Shropshire | On 1/30/2011 12:35 PM, Benjamin Shropshire wrote:
> On 1/23/2011 1:12 PM, Jason Evans wrote:
>> I converted the druntime repository from svn to git a few days ago, and I'm doing the same for phobos and dmd today. Please hold any pending changes you have until the conversion is complete, then commit your changes to the git repository. See https://github.com/D-Programming-Language for more information about the git repositories.
>>
>> For right now I'm focusing on getting the conversion done as quickly and smoothly as possible, but after it's done, I'll try to help people with general git configuration and work flow issues as necessary.
>>
>> Thanks,
>> Jason
>
> Seems I'm a bit out of the loop. What is the extent of the migration? Is the dsource SVN server being decommissioned and the rest of the projects being evicted/transplanted or is it just the ones that have already been moved? (FWIW, I don't use GIT and would rather not have to.)
There is no plans to shutdown any part of dsource. We've just migrated a few projects (ok, somewhat important ones) over to github: dmd, druntime, phobos, and a couple related packages. See the above url for the full list.
Later,
Brad
|
Copyright © 1999-2021 by the D Language Foundation