I have a rather strange use-case for a data type in a rpython interpreter.
What I need is a raw malloc, but with a custom GC hook. I understand how to
setup the GC hook, but what I can't figure out is what lltype to use with
malloc. This type will inherit directly from object so I don't need any
polymorphism. However I do need the struct to be of a variable size. So
something like the C struct hack:

struct MyObject {
   Type* header;
   char data[0];
}

Thanks,

Timothy
_______________________________________________
pypy-dev mailing list
pypy-dev@python.org
https://mail.python.org/mailman/listinfo/pypy-dev

Reply via email to