diff --git a/src/Instances/Identity/IdentityApply.php b/src/Instances/Identity/IdentityApply.php index 5924ebe..874bc79 100644 --- a/src/Instances/Identity/IdentityApply.php +++ b/src/Instances/Identity/IdentityApply.php @@ -39,7 +39,7 @@ public function map(callable $f, $a): Identity * @param HK1 $a * @return Identity * - * @psalm-pure + * @psalm-mutation-free * * @psalm-suppress LessSpecificImplementedReturnType */ diff --git a/src/Instances/Identity/IdentityFunctor.php b/src/Instances/Identity/IdentityFunctor.php index 8c6c6a3..c360a53 100644 --- a/src/Instances/Identity/IdentityFunctor.php +++ b/src/Instances/Identity/IdentityFunctor.php @@ -23,7 +23,7 @@ final class IdentityFunctor implements Functor * @param HK1 $a * @return Identity * - * @psalm-pure + * @psalm-mutation-free * * @psalm-suppress LessSpecificImplementedReturnType */ diff --git a/src/Instances/Identity/IdentityMonad.php b/src/Instances/Identity/IdentityMonad.php index 5693f76..efd0dd9 100644 --- a/src/Instances/Identity/IdentityMonad.php +++ b/src/Instances/Identity/IdentityMonad.php @@ -69,7 +69,7 @@ public function pure($a): Identity * @param callable(A): HK1 $f * @return Identity * - * @psalm-pure + * @psalm-mutation-free * * @psalm-suppress LessSpecificImplementedReturnType */ diff --git a/src/Instances/Identity/IdentityTraversable.php b/src/Instances/Identity/IdentityTraversable.php index 20f2c5c..d2f563b 100644 --- a/src/Instances/Identity/IdentityTraversable.php +++ b/src/Instances/Identity/IdentityTraversable.php @@ -56,14 +56,13 @@ public function foldr(callable $f, $b, HK1 $a) * @param HK1 $a * @return HK1> * - * @psalm-suppress ImplementedReturnTypeMismatch - * @psalm-suppress InvalidArgument * @psalm-suppress LessSpecificImplementedReturnType */ public function traverse(Applicative $applicative, callable $f, HK1 $a): HK1 { $identityA = Identity::fromBrand($a); + /** @psalm-suppress InvalidArgument */ return $applicative->map([Identity::class, 'wrap'], $f($identityA->unwrap())); } }