possible bug in free-identifier=?

Damien Mattei damien.mattei@gmail.com
Tue May 21 05:41:15 GMT 2024


ok in fact i did use it only for test, just at REPL ,when i will port my
code to Kawa i will know because i will use free-identifier=? in macro stx
(syntax parsing) at this time. Yes i hope to use for at least one procedure
even if the other are specific to Guile (SRFI 105 available but not in
other scheme implementation).
Damien

On Tue, May 21, 2024 at 1:50 AM Per Bothner <per@bothner.com> wrote:

> On 5/20/24 10:02 AM, Damien Mattei via Kawa wrote:
> > hello,
> >
> > i do not understand the behavior of free-identifier=? here:
> >
> > Kawa 3.1.1 (git describe: 3.1.1-0-gc47de33ad)
> >
> > (free-identifier=? #'sin #'sin)
> > java.lang.NullPointerException: Cannot invoke
> > "gnu.expr.Compilation.currentScope()" because "comp" is null
> > ...
> > why is there an error as i pass syntax objects as arguments to
> > free-identifier=? ?
>
> Not sure. But it looks like free-identifier=? only works inside a
> compilation context (such as when macro-expanding), but not during
> evaluation.
>
> Not sure how to fix this - or if should be fixed. Syntax objects aren't
> meant to be used during evaluation, except when evaluating a macro.
> --
>         --Per Bothner
> per@bothner.com   http://per.bothner.com/
>


More information about the Kawa mailing list