[Top][All Lists]

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

Re: GNUS Kerberos support, native GSSAPI?

From: Elias Mårtenson
Subject: Re: GNUS Kerberos support, native GSSAPI?
Date: Thu, 9 Feb 2017 21:02:11 +0800

On 9 February 2017 at 19:55, Joakim Jalap <address@hidden> wrote:

This is really cool :) Just looking over the code quickly it seems like
it would be useful to extract some of the functions in your module as a
sort of "emacs module lib". I mean things like bind_function, xcar,
xcdr, lisp_push (which is cons) and so on. Shouldn't everybody who
writes a module want most of these?

Just a thought :)

Thanks! And yes, I agree. This is my first attempt at writing something that uses the module API, and these are definitely functions that I cannot see anyone writing a module would not end up reimplementing.

In fact, I'd go as far as suggesting that some of the boilerplate should be provided by emacs-module itself. In particular, having to do env->intern(env, "nil") just to get a reference to nil is a bit crazy.

I tried putting all the interned symbols in a struct and passing specifying it as a data pointer when constructing the functions. However, this did not work as the emacs_value objects does not seem to have a lifetime outside of the invocation of a native function. I haven't seen this documented anywhere, so that was a bit surprising at first. The fact that this failed is the reason you see all the calls to env->intern everywhere.


reply via email to

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