[plt-scheme] scheme_primitive_module

From: Matthew Flatt (mflatt at cs.utah.edu)
Date: Wed Jan 4 23:54:08 EST 2006

At Tue, 3 Jan 2006 06:44:11 -0600, wayne at taxupdate.com wrote:
>    char buf[] = "(module test mzscheme "
>      "(require foreign)"
>      "(func)"
>      ")"
>      "(require test)";
>    scheme_eval_string(buf, env);

scheme_eval_string() reads a single S-expression, and ignores the rest
of the string.  (I've adjusted the docs to clarify this.)

So, you could change your example to

    char buf[] = "(begin (module test mzscheme "
      "(require foreign)"
      "(require test))";

and then it should work as you expect.


Posted on the users mailing list.