File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change 107107use PHPStan \PhpDoc \StubPhpDocProvider ;
108108use PHPStan \Reflection \Assertions ;
109109use PHPStan \Reflection \ClassReflection ;
110+ use PHPStan \Reflection \ExtendedMethodReflection ;
110111use PHPStan \Reflection \FunctionReflection ;
111112use PHPStan \Reflection \InitializerExprTypeResolver ;
112113use PHPStan \Reflection \MethodReflection ;
@@ -527,7 +528,7 @@ private function processStmtNode(
527528
528529 if ($ stmt ->getAttribute ('virtual ' , false ) === false ) {
529530 $ methodReflection = $ methodScope ->getFunction ();
530- if (!$ methodReflection instanceof MethodReflection ) {
531+ if (!$ methodReflection instanceof ExtendedMethodReflection ) {
531532 throw new ShouldNotHappenException ();
532533 }
533534 $ nodeCallback (new InClassMethodNode ($ methodReflection , $ stmt ), $ methodScope );
Original file line number Diff line number Diff line change 33namespace PHPStan \Node ;
44
55use PhpParser \Node ;
6- use PHPStan \Reflection \MethodReflection ;
6+ use PHPStan \Reflection \ExtendedMethodReflection ;
77
88/** @api */
99class InClassMethodNode extends Node \Stmt implements VirtualNode
1010{
1111
1212 public function __construct (
13- private MethodReflection $ methodReflection ,
13+ private ExtendedMethodReflection $ methodReflection ,
1414 private Node \Stmt \ClassMethod $ originalNode ,
1515 )
1616 {
1717 parent ::__construct ($ originalNode ->getAttributes ());
1818 }
1919
20- public function getMethodReflection (): MethodReflection
20+ public function getMethodReflection (): ExtendedMethodReflection
2121 {
2222 return $ this ->methodReflection ;
2323 }
You can’t perform that action at this time.
0 commit comments