mirror of
https://github.com/danog/psalm.git
synced 2024-11-27 04:45:20 +01:00
parent
78577fd624
commit
def7326ae1
@ -606,6 +606,7 @@ class TypeExpander
|
||||
}
|
||||
} elseif ($return_type->was_static && is_string($static_class_type) && $final) {
|
||||
$return_type->value = $static_class_type;
|
||||
$return_type->was_static = false;
|
||||
} elseif ($self_class && $return_type_lc === 'self') {
|
||||
$return_type->value = $self_class;
|
||||
} elseif ($parent_class && $return_type_lc === 'parent') {
|
||||
|
@ -903,6 +903,16 @@ class MethodSignatureTest extends TestCase
|
||||
[],
|
||||
'8.0'
|
||||
],
|
||||
'notExtendedStaticReturntypeInFinal' => [
|
||||
'<?php
|
||||
final class X
|
||||
{
|
||||
public static function create(): static
|
||||
{
|
||||
return new self();
|
||||
}
|
||||
}'
|
||||
],
|
||||
];
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user