This is the mail archive of the guile@sources.redhat.com mailing list for the Guile project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: call a C-routine as a Scheme function?


Han-Wen Nienhuys <hanwen@cs.uu.nl> writes:

> right now I first do gh_new_procedure2_0("foo-less", foo_less), and
> call scm_merge_x with gh_eval (gh_symbol2scm ("foo_less")). Surely
> there must be an easier way?

You can use

    SCM func = scm_make_gsubr ("foo-less", 2, 0, 0, foo_less);

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]