anchor.diff:  
       /// Trim [fact]'s allowed version if it's not covered by a requirement.
       required = _required[fact.allowed.name];
  -    if (required == null) return fact;
  +    if (required == null) return true;
   
       var result = _requiredAndAllowed(required, fact);
  -    if (result is! Disallowed) return result as Dependency;
  -
  -    _toProcess.add(result);
  -    return null;
  -  }
  -
  -  Dependency _dependencyIntoDisallowed(Dependency fact) {
  +    if (result == fact) return true;
  +    if (result != null) _replaceCurrent(result);
  +    return false;
  +  }
  +
  +  bool _dependencyIntoDisallowed(Dependency fact) {
       // Trim [fact] if some of its depender is disallowed.
       var disallowed = _disallowed[fact.depender.toRef()];
  -    if (disallowed != null) fact = _disallowedAndDepender(disallowed, fact);
  -    if (fact == null) return null;
  +    if (disallowed != null) {
  +      var result = _disallowedAndDepender(disallowed, fact);
  +      if (result != fact) {
  +        if (result != null) _replaceCurrent(result);
  +        return false;
  +      }
  +    }
   
       // Trim [fact] if some of its allowed versions are disallowed.
       disallowed = _disallowed[fact.allowed.toRef()];
  -    if (disallowed == null) return fact;
  -    var result = _disallowedAndAllowed(disallowed, fact);
  -    if (result is Dependency) return result;
  -
  -    // Add to [_toProcess] because [_fromCurrent] will get discarded when we
  -    // return `null`.
  -    _toProcess.add(result);
  -    return null;
  +    if (disallowed != null) {
  +      var result = _disallowedAndAllowed(disallowed, fact);
  +      if (result != fact) {
  +        if (result != null) _replaceCurrent(result);
  +        return false;
  +      }
  +    }
  +
  +    return true;
     }
   
     void _dependencyIntoIncompatibilities(Dependency fact) {
  
positive.code:     }
    }
  
    Dependency _dependencyIntoDependency(Dependency fact) {
      // Other dependencies from the same package onto the same target. This is
      // used later on to determine whether we can merge this with existing
      // dependencies.
  
negative.code:     if (required == null) return true;
      var result = _requiredAndIncompatibility(fact);
  
      if (result != null) _replaceCurrent(result);
      return false;
    }
  
    bool _incompatibilityIntoDisallowed(Incompatibility fact) {
      var disallowed = _disallowed[fact.dep1.toRef()];
      if (disallowed != null) {
        var result = _disallowedAndIncompatibility(disallowed, fact);
        if (result != incompatibility) {
          if (result != null) _replaceCurrent(result);
          return false;
        }
      }
  
      disallowed = _disallowed[fact.dep2.toRef()];
      if (disallowed != null) {
        var result = _disallowedAndIncompatibility(disallowed, fact);
        if (result != incompatibility) {
          if (result != null) _replaceCurrent(result);
          return false;
        }
      }
    }
  
    // Resolves [required] and [disallowed], which should refer to the same
  