[Top][All Lists]

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

Re: Nyacc: how to lex comments?

From: tomas
Subject: Re: Nyacc: how to lex comments?
Date: Tue, 17 Mar 2020 08:46:49 +0100
User-agent: Mutt/1.5.21 (2010-09-15)

On Mon, Mar 16, 2020 at 05:11:59PM -0700, Matt Wette wrote:
> On 3/16/20 2:39 PM, address@hidden wrote:
> >Hi,
> >
> >in my quest to play parsing, I'm failing when I try to cope with
> >comments.
> >


> make-comm-reader will not eat newlines at end of comment by default.
> If you want the comment # ... \n to include the newline try adding
> #:eat-newline #t.

D'oh, thanks. Also, I noticed I've to set #:comm-skipper in 'gen-lexer',
instead of #:comm-reader.

I didn't quite understand the difference between both. Would I have
to include comments explicitly in the grammar if the lexer uses

Thanks again
-- tomás

Attachment: signature.asc
Description: Digital signature

reply via email to

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