protected function forgetChangedClasses()
    {
        $frozenNamespaces = [];
        /** @var $package Package */
        foreach ($this->packageManager->getAvailablePackages() as $packageKey => $package) {
            if ($this->packageManager->isPackageFrozen($packageKey)) {
                $frozenNamespaces = array_merge($frozenNamespaces, $package->getNamespaces());
            }
        }
        $frozenNamespaces = array_unique($frozenNamespaces);

        $classNames = array_keys($this->classReflectionData);
        foreach ($frozenNamespaces as $namespace) {
            $namespace .= '\\';
            foreach ($classNames as $index => $className) {
                if (strpos($className, $namespace) === 0) {
                    unset($classNames[$index]);
                }
            }
        }

        foreach ($classNames as $className) {
            if (!$this->statusCache->has($this->produceCacheIdentifierFromClassName($className))) {
                $this->forgetClass($className);
            }
        }
    }