search for: sexp_val

Displaying 1 result from an estimated 1 matches for "sexp_val".

2009 Nov 28
1
PROTECT and OCaml GC.
...ions that are in charge of calling R for everything. Here's a simple example: > CAMLprim value r_findvar (value symbol) { > /* The findVar function is defined in envir.c. It looks up a symbol > in an environment. */ > CAMLparam1(symbol); > CAMLreturn(Val_sexp(findVar(Sexp_val(symbol), R_GlobalEnv))); > } This simply makes a call to findVar and returns the value to Objective Caml. It seems to me that I should be writing: > CAMLprim value r_findvar (value symbol) { > /* The findVar function is defined in envir.c. It looks up a symbol > in an environm...