File tree Expand file tree Collapse file tree 1 file changed +12
-4
lines changed Expand file tree Collapse file tree 1 file changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -119,6 +119,18 @@ private function resolveFunctionTypes(Node $node): void
119
119
return ;
120
120
}
121
121
122
+ $ this ->resolveParamTypes ($ node , $ docblock );
123
+
124
+ $ this ->resolveReturnValueType ($ node , $ docblock );
125
+
126
+ $ this ->resolveThrowsValueType ($ node , $ docblock );
127
+ }
128
+
129
+ /**
130
+ * @param Stmt\ClassMethod|Stmt\Function_|Expr\Closure|Expr\ArrowFunction $node
131
+ */
132
+ private function resolveParamTypes (Node $ node , Docblock $ docblock ): void
133
+ {
122
134
// extract param types from param tags
123
135
foreach ($ node ->params as $ param ) {
124
136
if (!$ this ->isTypeArray ($ param ->type )) { // not an array, nothing to do
@@ -138,10 +150,6 @@ private function resolveFunctionTypes(Node $node): void
138
150
139
151
$ param ->type = $ this ->resolveName (new Name ($ type ), Stmt \Use_::TYPE_NORMAL );
140
152
}
141
-
142
- $ this ->resolveReturnValueType ($ node , $ docblock );
143
-
144
- $ this ->resolveThrowsValueType ($ node , $ docblock );
145
153
}
146
154
147
155
/**
You can’t perform that action at this time.
0 commit comments