Take line classes into account for invalidating measurement caches