move some method calls out of the loop
add a cache for property inspections so we can avoid doing them
in every loop iteration