Deciding to install a package and wanting to install it, is not a conflict
parent
fea16b39a1
commit
8fd4e56029
|
@ -1113,6 +1113,8 @@ class Solver
|
||||||
|
|
||||||
protected function addDecision(Literal $l, $level)
|
protected function addDecision(Literal $l, $level)
|
||||||
{
|
{
|
||||||
|
assert($this->decisionMap[$l->getPackageId()] == 0);
|
||||||
|
|
||||||
if ($l->isWanted()) {
|
if ($l->isWanted()) {
|
||||||
$this->decisionMap[$l->getPackageId()] = $level;
|
$this->decisionMap[$l->getPackageId()] = $level;
|
||||||
} else {
|
} else {
|
||||||
|
@ -1123,6 +1125,9 @@ class Solver
|
||||||
protected function addDecisionId($literalId, $level)
|
protected function addDecisionId($literalId, $level)
|
||||||
{
|
{
|
||||||
$packageId = abs($literalId);
|
$packageId = abs($literalId);
|
||||||
|
|
||||||
|
assert($this->decisionMap[$packageId] == 0);
|
||||||
|
|
||||||
if ($literalId > 0) {
|
if ($literalId > 0) {
|
||||||
$this->decisionMap[$packageId] = $level;
|
$this->decisionMap[$packageId] = $level;
|
||||||
} else {
|
} else {
|
||||||
|
@ -1165,8 +1170,8 @@ class Solver
|
||||||
{
|
{
|
||||||
$packageId = abs($literalId);
|
$packageId = abs($literalId);
|
||||||
return (
|
return (
|
||||||
$this->decisionMap[$packageId] > 0 && !($literalId < 0) ||
|
($this->decisionMap[$packageId] > 0 && $literalId < 0) ||
|
||||||
$this->decisionMap[$packageId] < 0 && $literalId > 0
|
($this->decisionMap[$packageId] < 0 && $literalId > 0)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue