Skip to content

Commit

Permalink
Do not call function in loop
Browse files Browse the repository at this point in the history
  • Loading branch information
ravage84 committed May 7, 2020
1 parent 87683d3 commit 9d5f8d3
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/test/php/PHPMD/RuleSetTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,8 @@ private function createRuleSetFixture()
{
$ruleSet = new RuleSet();

for ($i = 0; $i < func_num_args(); ++$i) {
$funcNumArgs = func_num_args();
for ($i = 0; $i < $funcNumArgs; ++$i) {
$ruleSet->addRule(new RuleStub(func_get_arg($i)));
}

Expand Down

0 comments on commit 9d5f8d3

Please sign in to comment.