bundles / numpy 2.5.0.dev0+git20251130.2de293a / numpy / testing / _private / utils / assert_no_gc_cycles
function
numpy.testing._private.utils:assert_no_gc_cycles
source: build-install/usr/lib/python3.14/site-packages/numpy/testing/_private/utils.py :2621
Signature
def assert_no_gc_cycles ( * args , ** kwargs ) Summary
Fail if the given callable produces any reference cycles.
Extended Summary
If called with all arguments omitted, may be used as a context manager
with assert_no_gc_cycles(): do_something()
Parameters
func: callableThe callable to test.
\*args: ArgumentsArguments passed to func.
\*\*kwargs: KwargsKeyword arguments passed to func.
Returns
: Nothing. The result is deliberately discarded to ensure that all cycles: are found.
Aliases
-
numpy.testing.assert_no_gc_cycles