Case insensitive parsing leading to " Parameter shadowing super global" error
-
Hi and thanks for this very useful plugin,
The plugin raised the following error on our plugin WP-AppKit (https://github.com/uncatcrea/wp-appkit):
“ERROR | Parameter shadowing super global ($globals) causes fatal error since PHP 5.4”The error happens here for example: https://github.com/uncatcrea/wp-appkit/blob/master/wp-appkit/lib/components/components-types.php#L19 :
we use a var named “$globals” (lower case) and PHP Compatibility Checker sees it as “$GLOBALS” (upper case) and so says it conflicts with the super global $GLOBALS, which is not the case as PHP vars are case sensitive (WP-AppKit has already been tested with no errors on PHP5.4 to PHP7).Is there a specific reason why PHP Compatibility Checker does a case insensitive parsing? Or is it something that could/should be fixed on your side?
Thanks!
(FYI here is the commit we did so that WP-AppKit passes the PHP Compatibility Checker test with no “Parameter shadowing super global” error: https://github.com/uncatcrea/wp-appkit/commit/06cce00ed0e81840d01cb686b080a381abbfac16)
https://www.ads-software.com/plugins/php-compatibility-checker/
- The topic ‘Case insensitive parsing leading to " Parameter shadowing super global" error’ is closed to new replies.