File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -148,13 +148,14 @@ return $config
148
148
// for multiple, use ignoreErrorsOnPackagesAndPaths() or ignoreErrorsOnPackageAndPaths()
149
149
->ignoreErrorsOnPackageAndPath('symfony/console', __DIR__ . '/src/OptionalCommand.php', [ErrorType::SHADOW_DEPENDENCY])
150
150
151
- // allow using classes not present in composer's autoloader
151
+ // allow using non-autoloadable classes
152
152
// e.g. a library may conditionally support some feature only when Memcached is available
153
153
->ignoreUnknownClasses(['Memcached'])
154
+ ->ignoreUnknownClassesRegex('~^DDTrace~')
154
155
155
- // allow using classes not present in composer's autoloader by regex
156
- // e.g. when you want to ignore whole namespace of classes
157
- ->ignoreUnknownClassesRegex ('~^PHPStan\\.*? ~')
156
+ // allow using functions not defined during runtime
157
+ ->ignoreUnknownFunctions(['opcache_invalidate'])
158
+ ->ignoreUnknownFunctionsRegex ('~^opcache_ ~')
158
159
159
160
// force certain classes to be treated as used
160
161
// handy when dealing with dependencies in non-php files (e.g. DIC config), see example below
You can’t perform that action at this time.
0 commit comments