Thread overview
ev.d: D Programming Language "bindings" for libev.
Jan 26, 2008
Leandro Lucarella
Jan 26, 2008
Kenny B
Jan 27, 2008
Leandro Lucarella
Re: D Programming Language "bindings" for libev.
Jan 27, 2008
Kris
January 26, 2008
Hi! I wanted to play arround a little with the D programming languageD[1], specially with C interfacing, so I wrote this "bindings" for libev[2].

This was written using GDC (D 1.0), using phobos and libev 2.01 on a 32
bits
x86. I don't know if it works under other plataforms / combinations, but
I'll be very happy to know your experiences =)

For know there is only the same API as in C, but a more higher level API is planned. It took me a couple of hours to put it toguether (with testing, the struct alignment was the only "tricky" part).

I'm looking for some feedback before I start with the higher level API, so comments are much appreciated.

The "ev" module (ev.d) and a simple test (test.d) are attached.

You can compile it with: gdc -o test -lev ev.d test.d (you need libev 2.01 installed with EV_MULTIPLICITY=1, for now at least, if you have disabled some event types, take a look at version identifiers EV_ENABLE_SELECT and EV_XXX_ENABLE).

Of course, this isn't even a release yet, just a preview for comments, use it at your own risk ;)

TIA

[1] http://digitalmars.com/d/
[2] http://software.schmorp.de/pkg/libev.html

-- 
Leandro Lucarella (luca) | Blog colectivo: http://www.mazziblog.com.ar/blog/
----------------------------------------------------------------------------
GPG Key: 5F5A8D05 (F8CD F9A7 BF00 5431 4145  104C 949E BFB6 5F5A 8D05)
----------------------------------------------------------------------------
- Los romanos no tenían paz, loco... Necesitaban un poco de chala...


January 26, 2008
Leandro Lucarella wrote:
> Hi! I wanted to play arround a little with the D programming languageD[1], specially with C interfacing, so I wrote this "bindings" for libev[2].
> 

I had not heard of libev before (and used libevent a lot in C) -- this is great! It's even better that it's in D too! I'm gonna test it out on 64bit gdc later when I get time.

way awesome man!

Kenny
January 27, 2008
Kenny B, el 27 de enero a las 00:24 me escribiste:
> Leandro Lucarella wrote:
> > Hi! I wanted to play arround a little with the D programming languageD[1], specially with C interfacing, so I wrote this "bindings" for libev[2].
> 
> I had not heard of libev before (and used libevent a lot in C) -- this

I've used libevent a lot too (C/C++ too), and I'm planning to move to
libev =)

Even when I can't use for the real project, I plan to use D to do some prototyping (and who knows, if the prototype works well, maybe I can keep D ;)

> is great! It's even better that it's in D too! I'm gonna test it out on 64bit gdc later when I get time.

I'd love to know how did you do.

> way awesome man!

Thanks.

-- 
Leandro Lucarella (luca) | Blog colectivo: http://www.mazziblog.com.ar/blog/
----------------------------------------------------------------------------
GPG Key: 5F5A8D05 (F8CD F9A7 BF00 5431 4145  104C 949E BFB6 5F5A 8D05)
----------------------------------------------------------------------------
I've always been mad, I know I've been mad, like the most of us... very hard to explain why you're mad, even if you're not mad...
January 27, 2008
Nice!

Will be really interested to see how the higher-level API works out. Please keep us posted :)

- Kris


"Leandro Lucarella" <llucax@gmail.com> wrote in message news:20080126220211.GA16035@homero.springfield.home...
> Hi! I wanted to play arround a little with the D programming languageD[1], specially with C interfacing, so I wrote this "bindings" for libev[2].
>
> This was written using GDC (D 1.0), using phobos and libev 2.01 on a 32
> bits
> x86. I don't know if it works under other plataforms / combinations, but
> I'll be very happy to know your experiences =)
>
> For know there is only the same API as in C, but a more higher level API is planned. It took me a couple of hours to put it toguether (with testing, the struct alignment was the only "tricky" part).
>
> I'm looking for some feedback before I start with the higher level API, so comments are much appreciated.
>
> The "ev" module (ev.d) and a simple test (test.d) are attached.
>
> You can compile it with: gdc -o test -lev ev.d test.d (you need libev 2.01 installed with EV_MULTIPLICITY=1, for now at least, if you have disabled some event types, take a look at version identifiers EV_ENABLE_SELECT and EV_XXX_ENABLE).
>
> Of course, this isn't even a release yet, just a preview for comments, use it at your own risk ;)
>
> TIA
>
> [1] http://digitalmars.com/d/
> [2] http://software.schmorp.de/pkg/libev.html
>
> -- 
> Leandro Lucarella (luca) | Blog colectivo: http://www.mazziblog.com.ar/blog/
> ----------------------------------------------------------------------------
> GPG Key: 5F5A8D05 (F8CD F9A7 BF00 5431 4145  104C 949E BFB6 5F5A 8D05)
> ----------------------------------------------------------------------------
> - Los romanos no tenían paz, loco... Necesitaban un poco de chala...
>