emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Dynamic loading progress


From: Aurélien Aptel
Subject: Re: Dynamic loading progress
Date: Thu, 15 Oct 2015 01:48:03 +0200

On Thu, Oct 15, 2015 at 12:25 AM, Philipp Stephani
<address@hidden> wrote:
> static Lisp_Object value_to_lisp (emacs_value value) {
>   return value->v;
> }
>
> static emacs_value lisp_to_value (Lisp_Object object) {
>   emacs_value v = (emacs_value) malloc(sizeof v);
>   // The allocation needs to be smarter, this example leaks memory.
>   if (!v) return 0;
>   v->v = object;
>   return v;
> }

I'm not a big fan of a dynamically allocating memory for each
conversion, it's too expensive. Daniel solution seems more manageable.

By the way, I've merged your tls-errors branch in mine. But the API
doesn't have an unsafe funcall iiuc. That's fine with me but Stefan
was insistent on that.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]