diff --git a/src/Composer/DependencyResolver/PoolBuilder.php b/src/Composer/DependencyResolver/PoolBuilder.php index 38a5fac3c..1ccd3a80c 100644 --- a/src/Composer/DependencyResolver/PoolBuilder.php +++ b/src/Composer/DependencyResolver/PoolBuilder.php @@ -84,9 +84,9 @@ class PoolBuilder /** * @param int[] $acceptableStabilities array of stability => BasePackage::STABILITY_* value - * @psalm-param array $acceptableStabilities + * @psalm-param array $acceptableStabilities * @param int[] $stabilityFlags an array of package name => BasePackage::STABILITY_* value - * @psalm-param array $stabilityFlags + * @psalm-param array $stabilityFlags * @param array[] $rootAliases * @psalm-param array> $rootAliases * @param string[] $rootReferences an array of package name => source reference diff --git a/src/Composer/Package/Version/StabilityFilter.php b/src/Composer/Package/Version/StabilityFilter.php index ed27af080..df8c4bc16 100644 --- a/src/Composer/Package/Version/StabilityFilter.php +++ b/src/Composer/Package/Version/StabilityFilter.php @@ -22,6 +22,12 @@ class StabilityFilter /** * Checks if any of the provided package names in the given stability match the configured acceptable stability and flags * + * @param int[] $acceptableStabilities array of stability => BasePackage::STABILITY_* value + * @psalm-param array $acceptableStabilities + * @param int[] $stabilityFlags an array of package name => BasePackage::STABILITY_* value + * @psalm-param array $stabilityFlags + * @param string[] $names The package name(s) to check for stability flags + * @param string $stability one of 'stable', 'RC', 'beta', 'alpha' or 'dev' * @return bool true if any package name is acceptable */ public static function isPackageAcceptable(array $acceptableStabilities, array $stabilityFlags, $names, $stability) diff --git a/src/Composer/Repository/RepositoryInterface.php b/src/Composer/Repository/RepositoryInterface.php index 317368d10..afb99ca62 100644 --- a/src/Composer/Repository/RepositoryInterface.php +++ b/src/Composer/Repository/RepositoryInterface.php @@ -13,6 +13,7 @@ namespace Composer\Repository; use Composer\Package\PackageInterface; +use Composer\Package\BasePackage; use Composer\Semver\Constraint\ConstraintInterface; /** @@ -70,8 +71,10 @@ interface RepositoryInterface extends \Countable * - The namesFound returned are names which should be considered as canonically found in this repository, that should not be looked up in any further lower priority repositories * * @param ConstraintInterface[] $packageNameMap package names pointing to constraints - * @param array $acceptableStabilities - * @param array $stabilityFlags + * @param int[] $acceptableStabilities array of stability => BasePackage::STABILITY_* value + * @psalm-param array $acceptableStabilities + * @param int[] $stabilityFlags an array of package name => BasePackage::STABILITY_* value + * @psalm-param array $stabilityFlags * * @return array [namesFound => string[], packages => PackageInterface[]] * @psalm-return array{namesFound: string[], packages: PackageInterface[]}