Skip to content

Commit 38ac705

Browse files
committed
Bump psalm & fix issues
1 parent 3a0a285 commit 38ac705

File tree

3 files changed

+6
-5
lines changed

3 files changed

+6
-5
lines changed

Makefile

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,16 +13,15 @@ setup: install-phive
1313

1414
.PHONY: phpcs
1515
phpcs:
16-
docker run -it --rm -v${PWD}:/opt/project -w /opt/project phpdoc/phpcs-ga:v1.0.0 -s
16+
docker run -it --rm -v${PWD}:/opt/project -w /opt/project phpdoc/phpcs-ga:latest -s
1717

1818
.PHONY: phpstan
1919
phpstan:
2020
docker run -it --rm -v${PWD}:/opt/project -w /opt/project phpdoc/phpstan-ga:latest analyse src --no-progress --configuration phpstan.neon
2121

2222
.PHONY: psaml
2323
psalm:
24-
docker run -it --rm -v${PWD}:/opt/project -w /opt/project mickaelandrieu/psalm-ga
25-
24+
docker run -it --rm -v${PWD}:/opt/project -w /opt/project php:7.2 tools/psalm
2625
.PHONY: test
2726
test:
2827
docker run -it --rm -v${PWD}:/opt/project -w /opt/project php:7.2 tools/phpunit

phive.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<phive xmlns="https://phar.io/phive">
33
<phar name="phpunit" version="^8.4" installed="8.4.3" location="./tools/phpunit" copy="true"/>
4+
<phar name="psalm" version="^3.7.2" installed="3.7.2" location="./tools/psalm" copy="true"/>
45
</phive>

src/Types/ContextFactory.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@ final class ContextFactory
6464
public function createFromReflector(Reflector $reflector) : Context
6565
{
6666
if ($reflector instanceof ReflectionClass) {
67-
/** @var ReflectionClass<object> $reflector */
6867
return $this->createFromReflectionClass($reflector);
6968
}
7069

@@ -91,7 +90,9 @@ private function createFromReflectionParameter(ReflectionParameter $parameter) :
9190
{
9291
$class = $parameter->getDeclaringClass();
9392
if ($class) {
93+
//phpcs:ignore SlevomatCodingStandard.Commenting.InlineDocCommentDeclaration.MissingVariable
9494
/** @var ReflectionClass<object> $class */
95+
9596
return $this->createFromReflectionClass($class);
9697
}
9798

@@ -114,7 +115,7 @@ private function createFromReflectionClassConstant(ReflectionClassConstant $cons
114115
}
115116

116117
/**
117-
* @param ReflectionClass<object> $class
118+
* @phpstan-param ReflectionClass<object> $class
118119
*/
119120
private function createFromReflectionClass(ReflectionClass $class) : Context
120121
{

0 commit comments

Comments
 (0)