Skip to content

Commit

Permalink
Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
ondrejmirtes committed Mar 15, 2021
1 parent 4b1ad5d commit adacab8
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions src/Analyser/MutatingScope.php
Original file line number Diff line number Diff line change
Expand Up @@ -1882,8 +1882,8 @@ private function resolveType(Expr $node): Type
$this->getType($node->var),
$node->name->name,
$node
) ?? new NeverType();
if ($returnType instanceof NeverType && !$returnType->isExplicit()) {
);
if ($returnType === null) {
return new ErrorType();
}
return $returnType;
Expand Down Expand Up @@ -1915,8 +1915,8 @@ private function resolveType(Expr $node): Type
$staticMethodCalledOnType,
$node->name->toString(),
$node
) ?? new NeverType();
if ($returnType instanceof NeverType && !$returnType->isExplicit()) {
);
if ($returnType === null) {
return new ErrorType();
}
return $returnType;
Expand All @@ -1936,8 +1936,8 @@ private function resolveType(Expr $node): Type
$this->getType($node->var),
$node->name->name,
$node
) ?? new NeverType();
if ($returnType instanceof NeverType) {
);
if ($returnType === null) {
return new ErrorType();
}
return $returnType;
Expand Down Expand Up @@ -1972,8 +1972,8 @@ private function resolveType(Expr $node): Type
$staticPropertyFetchedOnType,
$node->name->toString(),
$node
) ?? new NeverType();
if ($returnType instanceof NeverType) {
);
if ($returnType === null) {
return new ErrorType();
}
return $returnType;
Expand Down

0 comments on commit adacab8

Please sign in to comment.