phpstan-disallowed-calls icon indicating copy to clipboard operation
phpstan-disallowed-calls copied to clipboard

When the call/usage is not found in `allowIn`, report error

Open spaze opened this issue 3 years ago • 0 comments

Given a configuration like this for example:

	disallowedFunctionCalls:
		-
			function: 'pcntl_*()'
			allowIn:
				- vendor/foo/bar/Baz.php

when any pcntl call is not found in vendor/foo/bar/Baz.php, report error and suggest removing the allowIn item to keep the config clean and up to date.

This is similar to what PHPStan reports when a ignoreErrors error wasn't hit.

spaze avatar Feb 27 '21 05:02 spaze