From: Miklos V. <vm...@fr...> - 2009-05-19 17:09:18
|
On Tue, May 19, 2009 at 04:53:25AM +0100, Olly Betts <ol...@su...> wrote: > I'm not aware of anything. The alternative would seem to be to use a > PHP associative array to map the object pointers to any extra data > required, which is probably slower and clunkier. The nice feature is > that it doesn't make every object bigger - there's only the overhead of > a failed hash lookup for objects which don't need this feature or > directors. It turns out we already had and were using swig_object_wrapper, just there was no way to alter its newobject variable from PHP. Here are two patches make it possible. The first patch does the real work, the second just adds an example. Do they look reasonable and may I commit them to my branch? Thanks. |