Klaas-Jan Stol wrote:

mmm, I looked at classes/none.pmc, this is a copy/paste:
===============
#include <assert.h>

static PMC * Py_None;

pmclass None singleton {

Ah, yep - None is a singleton too - sorry for my confusion.

So it should be rather easy to subclass None, implement get/set_pointer and use a distinct file-static PMC* storage for your singleton.

leo

Reply via email to