<div dir="ltr">Hi Rudolf, Bill would be the person to address this better than me, but I think the Egghead team should read through the s7.html page pretty closely to see if s7 is a good fit. It's pretty clear in there that there is *limited* R7RS compatibility, but that s7 is not R7RS and nor is that a stated goal. For example, s7 does not do macros with syntax-case or syntax-rules, but uses CL style macros. If R7RS is what you need, you might be better off with an implementation that makes that a goal, such as Chibi. I use s7 embedded in audio programs, which shares a fair bit of domain space with games, and I personally chose s7 because the performance and ease of embedding made up for that, but YMMV!<div><br></div><div>HTH</div><div>iain</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Jan 17, 2022 at 7:36 AM Rudolf Adamkovič <<a href="mailto:salutis@me.com">salutis@me.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi there!<br>
<br>
At Egghead Games, we would like to use Scheme for in-app scripting. We<br>
wired up s7 and SQLite to kick things off, but s7 support for R7RS does<br>
not seem to work. Below, I include some examples to illustrate my<br>
point.<br>
<br>
A basic example from the R7RS standard, page 54, …<br>
<br>
(with-exception-handler<br>
(lambda (x)<br>
(display "something went wrong\n"))<br>
(lambda ()<br>
(+ 1 (raise ’an-error))))<br>
<br>
… results in:<br>
<br>
> Error: catch error handler should accept two arguments: #<lambda (x)><br>
<br>
The simplest library …<br>
<br>
(load "r7rs.scm")<br>
(define-library (some lib)<br>
(export some-proc)<br>
(import (scheme base)<br>
(scheme r5rs))<br>
(begin<br>
(define (some-proc x)<br>
(display x))))<br>
<br>
… results in:<br>
<br>
> Error: symbol->value first argument, {gensym}-1, is a macro but should<br>
> be a symbol (define-macro ({gensym}-1 . names)...<br>
<br>
We picked s7 because the website says …<br>
<br>
> I believe it is compatible with r5rs and r7r<br>
<br>
… but per a quick grep, there seem to exist no tests for define-library<br>
or with-exception-handler.<br>
<br>
Any ideas?<br>
<br>
Rudy<br>
-- <br>
"Logic is a science of the necessary laws of thought, without which no<br>
employment of the understanding and the reason takes place." -- Immanuel<br>
Kant, 1785<br>
<br>
Rudolf Adamkovič <<a href="mailto:salutis@me.com" target="_blank">salutis@me.com</a>> [he/him]<br>
Studenohorská 25<br>
84103 Bratislava<br>
Slovakia<br>
<br>
_______________________________________________<br>
Cmdist mailing list<br>
<a href="mailto:Cmdist@ccrma.stanford.edu" target="_blank">Cmdist@ccrma.stanford.edu</a><br>
<a href="https://cm-mail.stanford.edu/mailman/listinfo/cmdist" rel="noreferrer" target="_blank">https://cm-mail.stanford.edu/mailman/listinfo/cmdist</a><br>
</blockquote></div>