unofficial mirror of guile-user@gnu.org 
 help / color / mirror / Atom feed
* Calling Scheme procedure from C ?
@ 2003-07-11  2:11 wangy01
  2003-07-13 18:18 ` Andreas Rottmann
  0 siblings, 1 reply; 2+ messages in thread
From: wangy01 @ 2003-07-11  2:11 UTC (permalink / raw)



I want to make a Scheme call "(write 10)" from my C code. I wrote:
 proc = scm_c_lookup("write");
 scm_apply(proc, SCM_MAKINUM(10), scm_listofnull);
but guile said:
        ERROR: In procedure apply:
        ERROR: Wrong type argument in position 1: #<variable 8096d70
binding: #<primitive-procedure write>>
, then I tried:
 proc = scm_c_lookup("write");
 scm_apply(proc, scm_cons(SCM_MAKINUM(10)), scm_listofnull);
guile printed the same error messages again.

What should I do?




_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://mail.gnu.org/mailman/listinfo/guile-user


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2003-07-13 18:18 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-07-11  2:11 Calling Scheme procedure from C ? wangy01
2003-07-13 18:18 ` Andreas Rottmann

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).