[Larceny-users] using srfi 27 and some other issues

Marijn Schouten (hkBst) hkBst at gentoo.org
Sat Feb 28 13:28:17 EST 2009


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi larcenists,

I've been working on packaging larceny 0.97b1 for Gentoo, partly because I
wanted to try it out on a small physics simulation project that I'm working on.
I'd like to detail some of the difficulties I ran into.

in doc/UserManual there are a lot of files with names that end in ".txt" which
lead me to believe they were just plain text. Apparently they are something
else. Perhaps the misleading extension could be changed?

For example from doc/UserManual/compiling.txt:
proc:compile-file[args="sourcefile",optargs="faslfile"]
lead me to believe there was a procedure `proc:compile-file'.

Next when I tried to compile my file I got this:


Larceny v0.97b1 (beta test) (Feb 28 2009 17:48:48, precise:Linux:unified)
larceny.heap, built on za feb 28 17:49:32 CET 2009

> (compile-file "ising.scm")


Error: get-datum: Lexical Error: Missing delimiter: -e  #<INPUT PORT ising.scm>
Entering debugger; type "?" for help.
debug> #<EOF>

>


An error that I could not understand. It turns out I was using an illegal
function name starting with a hyphen: -energy/J-plus

I'm really non-plussed that such names are illegal, but at least the error
message should be much clearer and it would be great if it would include a line
number.

My program uses SRFI 27 (random sources) and so I added a "(require 'srfi-27)"
at the beginning. Then I got this:

$ larceny -nobanner -- ising.scm -e "(main 100)"


Error: Undefined global variable "srfi-9".
Entering debugger; type "?" for help.
debug>


So I changed that to "(require 'srfi-9) (require 'srfi-27)" but it makes no
difference.

Finally I would like to note that having to double ctrl-D to exit each repl is
very annoying. To quit the above invocation I have to ctrl-D 8 times.

I did not attach my code as I'm not sure that it would be appreciated/needed but
I can do so. It's 167 line according to wc.

Marijn

PS please CC me as I'm not on the list

- --
Sarcasm puts the iron in irony, cynicism the steel.

Marijn Schouten (hkBst), Gentoo Lisp project, Gentoo ML
<http://www.gentoo.org/proj/en/lisp/>, #gentoo-{lisp,ml} on FreeNode
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkmpgkEACgkQp/VmCx0OL2xLUACdEIjCb1XYpu2RRxiOCtqQhy9Q
+l4An1dDIR+EacGgYf47f7aynlrRflM+
=WFEs
-----END PGP SIGNATURE-----



More information about the Larceny-users mailing list