File tree Expand file tree Collapse file tree 1 file changed +18
-11
lines changed
tests/PHPStan/Rules/Generics/data Expand file tree Collapse file tree 1 file changed +18
-11
lines changed Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ interface Scalar
99 /**
1010 * @return T
1111 */
12- public function value (): mixed ;
12+ public function value ();
1313}
1414
1515namespace MaxGoryunov \SavingIterator \Fakes ;
@@ -23,25 +23,32 @@ public function value(): mixed;
2323 */
2424class The implements Scalar
2525{
26+ /**
27+ * @var T
28+ */
29+ private $ subject ;
30+
31+ /**
32+ * @var Closure(T): mixed
33+ */
34+ private $ context ;
35+
2636 /**
2737 * @param T $subject
2838 * @param Closure(T): mixed $context
2939 */
3040 public function __construct (
31- /**
32- * @var T
33- */
34- private mixed $ subject ,
35- /**
36- * @var Closure(T): mixed
37- */
38- private Closure $ context
39- ) {
41+ $ subject ,
42+ $ context
43+ )
44+ {
45+ $ this ->subject = $ subject ;
46+ $ this ->context = $ context ;
4047 }
4148 /**
4249 * @return T
4350 */
44- public function value (): mixed
51+ public function value ()
4552 {
4653 ($ this ->context )($ this ->subject );
4754 return $ this ->subject ;
You can’t perform that action at this time.
0 commit comments