Valkertown Blog

I used to write about electronics…

Valkertown Blog header image 5

Entries Tagged as 'programming'

Writting Circular Lists in Erlang

March 18th, 2009 Comments

Well I have been struggling to find/create a circular buffer(list to be exact) on erlang, but I’m still not satisfied, I have hacked this:

[_P | T ] = lists:reverse(O),

    N = [ V | lists:reverse(T)],

To insert V in the head and remove P from the tail. But can you see the problem with that: [...]

Tags:   ·

Swig Python

January 21st, 2008 Comments

Bueno, hace poco jugue un poco con Swig,
para generar modulos de python desde c en particular.
Resulta una tarea muy simple
Escribi un Makefile que ilustra los pasos de una forma más o menos
simple, este Makefile esta más bien orientado a Slackware 12 pero
se puede saber facilmente que partes deben ser modificadas para otros
*nix.

#Makefile

MODULE=anything

all:
swig -Wall -python [...]

Tags:   · ·