Skip to content

Commit 6864a44

Browse files
committed
wrap top level code in function
1 parent 8156b17 commit 6864a44

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tests/PHPStan/Rules/Properties/data/bug-10048.php

+3-1
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,6 @@ public function useCallback(): void
2828
}
2929
}
3030

31-
(new Foo())->useCallback();
31+
function doFoo() {
32+
(new Foo())->useCallback();
33+
}

0 commit comments

Comments
 (0)