Expected: there's no error for code that imports type SerializableError
Actual:
ERROR: [InvalidTypeImport](https://psalm.dev/233) - 34:25 - Type alias SerializableError imported from ExecutionResult is not defined on the source class
/**
* @internal
*
* @phpstan-import-type SerializableError from ExecutionResult
*/
class Foo
{
/**
* @return SerializableError
*/
public function format(\Throwable $error): array
{
return [
'message' => 'message',
];
}
}
Phpstan playground https://phpstan.org/r/5da87ef6-9869-40ca-b851-d4edcac82fba Psalm playground https://psalm.dev/r/22d155399e
Source (exported types): https://github.com/webonyx/graphql-php/blob/29b5b613bd3ee34f227650f856ee8dd4ce151b88/src/Executor/ExecutionResult.php#L9-L34
Expected: there's no error for code that imports type
SerializableError
Actual: