WordPress-Coding-Standards/Test
jrfnl 694c459b5a Performance: use FQN for functions which can use PHP7 compile time opcodes
Functions in PHP are namespaced as well, however, when PHP cannot find the function in the namespace, it will fall through to the global namespace.

The step to first check within the namespace can be skipped by either using `use func ...` (PHP 5.6+) or by prefixing the function with a `\`.

While this offers a small performance gain as a general practice, using this for the special compiled functions should offer a noticeable performance gain when running WPCS on PHP 7+.
The special compiled function are replaced by opcodes at compile time, but only if it's clear at compile time that the global PHP native functions will be used.
For the list of functions, see: f2db305fa4/Zend/zend_compile.c (L3872)

This PR implements this throughout the codebase.
2018-07-05 20:48:51 +02:00
..
Standards Performance: use FQN for functions which can use PHP7 compile time opcodes 2018-07-05 20:48:51 +02:00
AllTests.php PHPCS 3.x compat: Get the unit tests working on both PHPCS 2.x as well as 3.x 2017-07-24 08:47:58 +02:00
bootstrap.php Adjust the URL to the contributing file where relevant 2017-07-27 15:39:54 +02:00
phpcs2-bootstrap.php Fix up existing WPCS code / multiple statement assignment operator alignment 2017-10-07 14:39:47 +02:00
phpcs3-bootstrap.php Performance: use FQN for functions which can use PHP7 compile time opcodes 2018-07-05 20:48:51 +02:00