grammatica-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Grammatica-users] Comment lines starts with '*'


From: Per Cederberg
Subject: Re: [Grammatica-users] Comment lines starts with '*'
Date: Mon, 18 Apr 2005 19:45:28 +0200

Hi,

Yes, this is problem. Currently it is not possible to do in a
good way, as the regular expression interpreter in Grammatica
lacks support for ^ and $... What you can do, however, is a
dirty little trick:

    parser.parse("\n" + inputString);

If your grammar ignores additional newlines, this will work
perfectly. There is an old outstanding bug on this, #3597:

https://savannah.nongnu.org/bugs/index.php?func=detailitem&item_id=3597

I've raised it's priority so that it'll be fixed by the next
release. (Which, by the way, I should start working on any
month now... ;-)

Cheers,

/Per

On mon, 2005-04-18 at 15:09 +0200, address@hidden wrote:
> Hi, 
>  
> Great product. 
>  
> How do I deal with comment lines that start with a '*'. 
> If its not at the beginning of line then its not a comment. 
>  
> Got WS = <<[\r\n]\*.*>> 
>  
> This works for every line except for the first line - it 
> does have a prevoius line. 
>  
> begin = [ star ] statements; 
>  
> star = '*' skip to end of line  
>  
> How do I do this. 
>  
> Regards, 
> Theo 






reply via email to

[Prev in Thread] Current Thread [Next in Thread]