The expression return $this->relativeFileName could return the type null which is incompatible with the type-hinted return DaveLiddament\StaticAnal...Common\RelativeFileName. Consider adding an additional type-check to rule them out.
Loading history...
45
}
46
47
public function getLineNumber(): LineNumber
48
{
49
Assert::notNull($this->lineNumber, 'Trying to get LineNumber when PreviousLocation is not set');
The expression return $this->lineNumber could return the type null which is incompatible with the type-hinted return DaveLiddament\StaticAnal...omain\Common\LineNumber. Consider adding an additional type-check to rule them out.