From guillaume.yziquel at citycable.ch  Sun Nov 29 19:57:27 2009
From: guillaume.yziquel at citycable.ch (Guillaume Yziquel)
Date: Sun, 29 Nov 2009 19:57:27 +0100
Subject: [Rd] PROTECT and OCaml GC.
In-Reply-To: <F11B6C18-26EC-41F8-9EEB-A614D16945AC@r-project.org>
References: <4B11B75C.9070806@citycable.ch>
	<8ec76080911281625q5d5b8824hefb14af9b23d29f0@mail.gmail.com>
	<4B11C55E.2060909@citycable.ch>
	<F11B6C18-26EC-41F8-9EEB-A614D16945AC@r-project.org>
Message-ID: <4B12C417.1050308@citycable.ch>

Simon Urbanek a ?crit :
> On Nov 28, 2009, at 7:50 PM, Guillaume Yziquel wrote:
> 
> FWIW what I think you should be really looking at is R_PreserveObject/R_ReleaseObject.

OK. Thanks.

> I would suggest looking at the many other R embeddings in other languages that already exist since I don't think you approach is very viable (but I think I expressed that already before).

Lisp - the only thing I've seen is a translator:

http://dan.corlan.net/R_to_common_lisp_translator/

I haven't found a binding for Haskell. Nor for Scheme.

Do you know of any bindings of R to functional languages?

> since I don't think you approach is very viable (but I think I expressed that already before).

You expressed the sentiment that it would be a very bad idea to bypass 
the current API. I would be happy to hear why you would think that a 
low-level binding is not possible, or not very viable.

By low-level, I mean a binding that takes hold of R objects without 
using symbols all over to reference them. (Using symbols in the formals, 
the body or the environment of a closure is fine, for instance, but I'd 
like to execute a closure directly, and eventually be able to construct 
R closure from OCaml functions).

Please elaborate on the difficulties you perceive. That would be helpful.

> Cheers,
> Simon

All the best,

Guillaume.

-- 
      Guillaume Yziquel
http://yziquel.homelinux.org/



[Rd] PROTECT and OCaml GC.
Guillaume Yziquel