Re: [Pythonocc-users] Crash with GarbageCollector and some TopTools classes

2011-05-19 Thread Thomas Paviot
2011/5/16 Frank Conradie > Hi Thomas > > I recently ran into a crash when calling the GarbageCollector smart_purge > method, and finally figured out that it was because of TopTools_XX > references returned by some TopTools_XX classes, for which _kill_pointed() > should of course *not* be called.

Re: [Pythonocc-users] Crash with GarbageCollector and some TopTools classes

2011-05-19 Thread Thomas Paviot
Hi Frank, SWIG already implements this feature: the thisown flag is set to True is the wrapped object owns the underlying C++ instance (see http://www.swig.org/Doc2.0/SWIGPlus.html). In this case, deleting the python object calls the C++ destructor. The flag 'thisown' is defined for one class. The