Re: flex for windows

Chris F Clark <cfc@shell01.TheWorld.com>
Mon, 07 Jan 2008 09:10:26 -0500

          From comp.compilers

Related articles
[9 earlier articles]
Re: flex for windows DrDiettrich1@aol.com (Hans-Peter Diettrich) (2008-01-06)
Re: flex for windows dickey@saltmine.radix.net (Thomas Dickey) (2008-01-06)
Re: flex for windows dickey@saltmine.radix.net (Thomas Dickey) (2008-01-06)
Re: flex for windows agdjh@gasjgdjagjdagdgaj.com (Gary R. Van Sickle) (2008-01-06)
Re: flex for windows tprince@computer.org (Tim Prince) (2008-01-06)
Re: flex for windows DrDiettrich1@aol.com (Hans-Peter Diettrich) (2008-01-07)
Re: flex for windows cfc@shell01.TheWorld.com (Chris F Clark) (2008-01-07)
Re: flex for windows rlb@hoekstra-uitgeverij.nl (2008-01-09)
Re: flex for windows monnier@iro.umontreal.ca (Stefan Monnier) (2008-01-21)
| List of all articles for this month |
From: Chris F Clark <cfc@shell01.TheWorld.com>
Newsgroups: comp.compilers,comp.lang.c
Date: Mon, 07 Jan 2008 09:10:26 -0500
Organization: The World Public Access UNIX, Brookline, MA
References: 07-12-040 07-12-043 07-12-047 07-12-053 07-12-056 08-01-013 08-01-023
Keywords: Windows, lex
Posted-Date: 08 Jan 2008 12:24:25 EST

Hans-Peter Diettrich <DrDiettrich1@aol.com> writes:


> Gary R. Van Sickle wrote:
>
>> Apparently NP-Hard "\r\n" Vs. "\n" EOL Problem".
>
> What's the problem?
>
> AFAIK a single "\r" is nowhere used for EOL, so it should be possible to
> skip \r, and treat \n as EOL.
>
> DoDi
> [That's pretty typical, ignore the \r and look for the \n. But this doesn't
> have much to do with compilers, as opposed to general Windows programming,
> any more. -John]


Doesn't MacOS use a single \r to represent EOL rather than single \n?


However, the issue is more whether any given tool treats the
combinations of \r and \n characters in your file the way that you (or
some other tool you use) intended them to be treated (as a result I
have my own version of u2d and d2u that cannonicalizes them in the
ways that the tools I use accept them), so as our moderator said it
isn't much of a compiler question as a global question, with the
problem being that there is no universally accepted standard. Yes,
there are standards, but they aren't universally followed.


BTW, anyone who wants my copy of u2d/d2u and/or the Yacc++ grammar I
used in writing them, (Yes, I wrote a grammar to "parse" the problem.)
can get a free copy by writing me.


Hope this helps,
-Chris


*****************************************************************************
Chris Clark Internet : compres@world.std.com
Compiler Resources, Inc. Web Site : http://world.std.com/~compres
23 Bailey Rd voice : (508) 435-5016
Berlin, MA 01503 USA fax : (978) 838-0263 (24 hours)


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.