From: "Iñaki Baz Castillo" Date: 2008-04-23T05:05:24+09:00 Subject: Re: Treetop parser (or PEG in general?) questions El Martes, 22 de Abril de 2008, Phil Tomson escribió: > On 4/22/08, Iñaki Baz Castillo wrote: > > El Martes, 22 de Abril de 2008, Phil Tomson escribió: > > > The first testcase (test_eol_comment) fails, but the second one > > > > > > passes. Any idea what's wrong with that comment_to_eol rule? > > > > Are you sure? both cases work for me. > > > > -- > > > > Iñaki Baz Castillo > > I found out on #treetop IRC that I need to change the comment_eol rule to: > > rule comment_to_eol > '--' (!"\n" .)+ "\n" > end > > Then it'll match: "--this is a comment\n" Yes sorry, I tested it via a bash script with command parameters, so writting "\n" doesn't create a LF but a literal \n. -- Iñaki Baz Castillo