From 8d861ab195ddc488fc36380fbefb6bd094451532 Mon Sep 17 00:00:00 2001 From: jrfnl Date: Fri, 5 Jul 2019 01:29:57 +0200 Subject: [PATCH] WordPress ruleset: efficiency fix Rulesets are processed top-to-bottom, one rule at the time. For the `WordPress` ruleset, this means that PHPCS would first load the `WordPress-Core` ruleset and process all rules in that file, then read the `WordPress-Docs` ruleset and lastly, the `WordPress-Extra` ruleset. As the `WordPress-Extra` ruleset includes `WordPress-Core`, it would re-process the `WordPress-Core` ruleset a second time and then process the additional rules in the `Extra` ruleset. This means that in effect, the `WordPress-Core` ruleset is processed twice when using the `WordPress` ruleset which is inefficient. By commenting that rule out, we still document that the `WordPress` ruleset includes `WordPress-Core` without double processing the ruleset. --- WordPress/ruleset.xml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/WordPress/ruleset.xml b/WordPress/ruleset.xml index 80bfb8d3bf..fd24ae6318 100644 --- a/WordPress/ruleset.xml +++ b/WordPress/ruleset.xml @@ -3,7 +3,10 @@ WordPress Coding Standards +