From 1f0d0128451a5c1aed79da9607c49c80125cdc34 Mon Sep 17 00:00:00 2001 From: Jordi Boggiano Date: Mon, 28 Oct 2024 21:37:23 +0100 Subject: [PATCH] Add hint how ambiguous class issues can be resolved, refs #6221 (#12179) --- src/Composer/Autoload/AutoloadGenerator.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Composer/Autoload/AutoloadGenerator.php b/src/Composer/Autoload/AutoloadGenerator.php index 86c9f184d..44431128f 100644 --- a/src/Composer/Autoload/AutoloadGenerator.php +++ b/src/Composer/Autoload/AutoloadGenerator.php @@ -34,6 +34,7 @@ use Composer\Script\ScriptEvents; use Composer\Util\PackageSorter; use Composer\Json\JsonFile; use Composer\Package\Locker; +use Symfony\Component\Console\Formatter\OutputFormatter; /** * @author Igor Wiedler @@ -380,6 +381,9 @@ EOF; ); } } + if (\count($ambiguousClasses) > 0) { + $this->io->writeError('To resolve ambiguity in classes not under your control you can ignore them by path using exclude-files-from-classmap'); + } // output PSR violations which are not coming from the vendor dir $classMap->clearPsrViolationsByPath($vendorPath);