From: <tomas@tuxteam.de>
To: guile-user@gnu.org
Subject: Re: Nyacc: how to lex comments?
Date: Tue, 17 Mar 2020 08:46:49 +0100 [thread overview]
Message-ID: <20200317074649.GA27693@tuxteam.de> (raw)
In-Reply-To: <b225fc61-c22a-d77f-b0d9-07df75ba2414@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 669 bytes --]
On Mon, Mar 16, 2020 at 05:11:59PM -0700, Matt Wette wrote:
> On 3/16/20 2:39 PM, tomas@tuxteam.de 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
#:comment-reader?
Thanks again
-- tomás
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 198 bytes --]
next prev parent reply other threads:[~2020-03-17 7:46 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-16 21:39 Nyacc: how to lex comments? tomas
2020-03-17 0:11 ` Matt Wette
2020-03-17 7:46 ` tomas [this message]
2020-03-17 12:31 ` Matt Wette
2020-03-17 12:42 ` tomas
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/guile/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200317074649.GA27693@tuxteam.de \
--to=tomas@tuxteam.de \
--cc=guile-user@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).