fixed GC behavior for custom objects, more asserts