Dear list,

I have a question about the foreign module. Given the following definition:

   (defineparse(foreign-safe-lambda*scheme-object(((constc-string)
   filename))
   "C_word out = P(filename); C_return(out);"
   ))

and

   externC_wordP(constchar*filename)
   {
   char*str="hello world";
   intlength=strlen(str);
   C_word*ptr=C_alloc(C_SIZEOF_STRING(length));
   C_wordres=C_string(&ptr, length, str);
   returnres;
   }

When I use the parse function on a string, I get the following output:
#(#<procedure> #<procedure C_values> (#(#<procedure> #...
How can I allocate Scheme object from a C function (possibly recursive)?
Thank you all in advance,
Massimo

Reply via email to