def test_no_return(self):

        @njit
        def foo(n):
            for i in range(n):
                temp = np.zeros(2)
            return 0

        n = 10
        init_stats = rtsys.get_allocation_stats()
        foo(10)
        cur_stats = rtsys.get_allocation_stats()
        self.assertEqual(cur_stats.alloc - init_stats.alloc, n)
        self.assertEqual(cur_stats.free - init_stats.free, n)
Test issue #1291
dataset/ETHPy150Open numba/numba/numba/tests/test_nrt_refct.py/TestNrtRefCt.test_no_return