1
0
Fork 0

CS: Typehint array, remove unnecessary docblock, call spl_object_hash once

pull/9312/head
Nils Adermann 2020-10-21 18:11:24 +02:00
parent 7b4cb9c370
commit 9338401be7
1 changed files with 3 additions and 7 deletions

View File

@ -514,16 +514,12 @@ class Solver
return array($learnedLiterals[0], $ruleLevel, $newRule, $why);
}
/**
* @param Problem $problem
* @param Rule $conflictRule
*/
private function analyzeUnsolvableRule(Problem $problem, Rule $conflictRule, &$ruleSeen)
private function analyzeUnsolvableRule(Problem $problem, Rule $conflictRule, array &$ruleSeen)
{
$ruleSeen[spl_object_hash($conflictRule)] = true;
$why = spl_object_hash($conflictRule);
$ruleSeen[$why] = true;
if ($conflictRule->getType() == RuleSet::TYPE_LEARNED) {
$why = spl_object_hash($conflictRule);
$learnedWhy = $this->learnedWhy[$why];
$problemRules = $this->learnedPool[$learnedWhy];