Fixed CollectBasicObject test by lostmsu · Pull Request #1313 · pythonnet/pythonnet
This contains two fixes, that must go along for the tests to pass:
- Fixed the
CollectBasicObjectandCollectOnShutdowntests for Mono by fixingMakeAGarbagefunction to not keep the garbage on the stack during a conservative roots scan (looks like Mono scans some variables, that are already gone). - Fixed the crash during runtime shutdown by further simplifying
Finalizerto only store raw pointers to python objects instead of instances ofIPyDisposableand thus replacing Dispose with reliable and simpleDecRef.
This removes some functions from Finalizer, which previously were public, but should not have been.