Ignore break line sometimes

Geovani de Souza <geovanisouza92@gmail.com>
Sat, 11 Feb 2012 06:56:17 -0800 (PST)

          From comp.compilers

Related articles
Ignore break line sometimes geovanisouza92@gmail.com (Geovani de Souza) (2012-02-11)
Re: Ignore break line sometimes DrDiettrich1@aol.com (Hans-Peter Diettrich) (2012-02-11)
Re: Ignore break line sometimes gneuner2@comcast.net (George Neuner) (2012-02-11)
RE: Ignore break line sometimes uu3kw29sb7@snkmail.com (Karsten Nyblad) (2012-02-12)
Re: Ignore break line sometimes monnier@iro.umontreal.ca (Stefan Monnier) (2012-02-12)
Re: Ignore break line sometimes Pidgeot18@verizon.invalid (Joshua Cranmer) (2012-02-12)
Re: Ignore break line sometimes kaz@kylheku.com (Kaz Kylheku) (2012-02-13)
[5 later articles]
| List of all articles for this month |

From: Geovani de Souza <geovanisouza92@gmail.com>
Newsgroups: comp.compilers
Date: Sat, 11 Feb 2012 06:56:17 -0800 (PST)
Organization: Compilers Central
Keywords: parse, question
Posted-Date: 11 Feb 2012 10:17:24 EST

Hi all!


I'm trying write an parser to my compiler, and I'm interessed to ignore the break line (\n) sometimes. E.g:


if true then [\n]
    foo(); [\n]
end; [\n]


So, in the first line, the '\n' after 'then' isn't important, but in the second "foo();" could replace the need of the semicolon to conclude the statement, or still, in the 'end'.


Too ignore '\n' in the white lines.


How can I do this?



Post a followup to this message

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