[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: |
Mon, 28 Sep 2015 18:12:13 +0200 |
On Mon, Sep 28, 2015 at 5:42 PM, Philipp Stephani <address@hidden> wrote:
> What is the use case for this? Is the "user_ptr" functionality really
> needed?
Most libraries creates opaque pointers type you re-use for each calls.
See some libarchive samples for example [1]
Imagine porting libarchive to emacs as a module. You would use a
struct archive pointer stored as a user pointer in an Emacs value. And
the new lisp functions would be very similar to the libarchive API
i.e. taking the struct archive handle as a parameter.
We might not have deteminist finalizer but we could come up with a
lisp macro similar to Python 'with' keyword [2] that would set up an
unwind-protect that calls the finalizer.
1:
https://github.com/libarchive/libarchive/wiki/Examples#List_contents_of_Archive_stored_in_File
2: http://effbot.org/zone/python-with-statement.htm
- Re: Dynamic loading progress, (continued)
- Re: Dynamic loading progress, Stefan Monnier, 2015/09/14
- Re: Dynamic loading progress, Daniel Colascione, 2015/09/14
- Re: Dynamic loading progress, Aurélien Aptel, 2015/09/24
- Re: Dynamic loading progress, Stefan Monnier, 2015/09/24
- Re: Dynamic loading progress, Aurélien Aptel, 2015/09/26
- Re: Dynamic loading progress, Stefan Monnier, 2015/09/27
- Re: Dynamic loading progress, Aurélien Aptel, 2015/09/28
- Re: Dynamic loading progress, Davis Herring, 2015/09/29
- Re: Dynamic loading progress, Stephen Leake, 2015/09/29
- Re: Dynamic loading progress, Philipp Stephani, 2015/09/29
- Re: Dynamic loading progress,
Aurélien Aptel <=
- Re: Dynamic loading progress, Stefan Monnier, 2015/09/29
- Re: Dynamic loading progress, Daniel Colascione, 2015/09/29
- Re: Dynamic loading progress, Stefan Monnier, 2015/09/30
- Re: Dynamic loading progress, Philipp Stephani, 2015/09/29
- Re: Dynamic loading progress, Philipp Stephani, 2015/09/29
- Re: Dynamic loading progress, Stefan Monnier, 2015/09/29
- Re: Dynamic loading progress, Philipp Stephani, 2015/09/29
- Re: Dynamic loading progress, Stefan Monnier, 2015/09/29
- Re: Dynamic loading progress, Daniel Colascione, 2015/09/29
- Re: Dynamic loading progress, Daniel Colascione, 2015/09/29