From: Matt Wette <matt.wette@gmail.com>
To: Jan Nieuwenhuizen <janneke@gnu.org>
Cc: Guile User <guile-user@gnu.org>
Subject: Re: [ANN] nyacc 0.80.4 released
Date: Wed, 2 Aug 2017 05:13:43 -0700 [thread overview]
Message-ID: <70EB26F7-B52B-4E4D-9CDE-D5CA7803E7EC@gmail.com> (raw)
In-Reply-To: <878tj2zgo6.fsf@gnu.org>
> On Aug 1, 2017, at 10:23 PM, Jan Nieuwenhuizen <janneke@gnu.org> wrote:
>
> Matt Wette writes:
>
>> Thanks for the reports. I am happy to see the severity in bugs reducing.
>
> Yes!
>
>> For the FFI-helper I need to parse the rat’s nest under /usr/include
>> so I am catching more.
>
> Hah :-)
>
>> I am not sure what you are getting at here. If I have
>> char *s = “foo\0bar”;
>> then the tree is
>> (trans-unit
>> (decl (decl-spec-list (type-spec (fixed-type "char")))
>> (init-declr-list
>> (init-declr
>> (ptr-declr (pointer) (ident "s"))
>> (initzer (p-expr (string "foo\x00bar")))))))
>> so the null character makes it into the tree. The tree language is SXML so this should be a
>> legal Scheme string, which I think it is. See http://dl.acm.org/citation.cfm?doid=571727.571736.
>
> Hmm, weird are you using my null.c? Here's what I get
>
> --8<---------------cut here---------------start------------->8---
> 07:18:50 janneke@dundal:~/src/nyacc [env]
> $ guile
> GNU Guile 2.2.2
> Copyright (C) 1995-2017 Free Software Foundation, Inc.
>
> Guile comes with ABSOLUTELY NO WARRANTY; for details type `,show w'.
> This program is free software, and you are welcome to redistribute it
> under certain conditions; type `,show c' for details.
>
> Enter `,help' for help.
> scheme@(guile-user)> (use-modules (nyacc lalr))
> scheme@(guile-user)> *nyacc-version*
> $1 = "0.80.4"
> scheme@(guile-user)> (use-modules (nyacc lang c99 parser))
> scheme@(guile-user)> (with-input-from-file "null.c" parse-c99)
> $2 = (trans-unit (decl (decl-spec-list (type-spec (fixed-type "char"))) (init-declr-list (init-declr (ptr-declr (pointer) (ident "s")) (initzer (p-expr (string "foo0bar")))))))
> scheme@(guile-user)>
> --8<---------------cut here---------------end--------------->8---
>
>
>> Look for fixes to above, along with some (minor) changes in c99 output, in 0.81.0.
>
> Thanks!
>
> Greetings,
> janneke
>
> --
> Jan Nieuwenhuizen <janneke@gnu.org> | GNU LilyPond http://lilypond.org
> Freelance IT http://JoyofSource.com | Avatar® http://AvatarAcademy.com <http://avataracademy.com/>
You are right. If I use the string parser it parses correctly. If I use the file parser it does not.
I need to check this out.
Matt
next prev parent reply other threads:[~2017-08-02 12:13 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-28 23:47 [ANN] nyacc 0.80.4 released Matt Wette
2017-08-01 20:53 ` Jan Nieuwenhuizen
2017-08-01 23:10 ` Matt Wette
2017-08-02 5:23 ` Jan Nieuwenhuizen
2017-08-02 12:13 ` Matt Wette [this message]
2017-08-02 12:22 ` Matt Wette
2017-08-04 10:31 ` Jan Nieuwenhuizen
2017-08-04 17:38 ` Matt Wette
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=70EB26F7-B52B-4E4D-9CDE-D5CA7803E7EC@gmail.com \
--to=matt.wette@gmail.com \
--cc=guile-user@gnu.org \
--cc=janneke@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).