It has one caveat, @timeit
generates allocations on its own. So, nested calls are slightly biased. It is not a big problem, but can be source of confusion, when you have nice tight allocationless loop, but outer @timeit
shows you that allocations exists.
4 Likes