anchor.diff:            'subpackageRules');
         return;
       }
  -    if (!srcSubpackageRules.mayImportAnalyzer &&
  -        dst.pathSegments[0] == 'analyzer') {
  -      problem('$src depends on $dst, but subpackage "$srcSubpackage" may not '
  -          'import analyzer');
  +    srcSubpackageRules.actuallyContainsFiles = true;
  +    if (dst.pathSegments[0] == 'analyzer') {
  +      if (srcSubpackageRules.mayImportAnalyzer) {
  +        srcSubpackageRules.actuallyImportsAnalyzer = true;
  +      } else {
  +        problem('$src depends on $dst, but subpackage "$srcSubpackage" may not '
  +            'import analyzer');
  +      }
       }
       var dstSubPackage = subpackageForUri(dst);
       if (dstSubPackage == null) return;
       if (dstSubPackage == srcSubpackage) return;
  -    if (!srcSubpackageRules.allowedDependencies.contains(dstSubPackage)) {
  +    if (srcSubpackageRules.allowedDependencies.contains(dstSubPackage)) {
  +      srcSubpackageRules.actualDependencies.add(dstSubPackage);
  +    } else {
         problem('$src depends on $dst, but subpackage "$srcSubpackage" is not '
             'allowed to depend on subpackage "$dstSubPackage"');
       }
  
positive.code:     if (subpackage == null) {
        problem('Uri $src is inside package:front_end but is not in any known '
            'subpackage');
      } else if (!subpackageRules[subpackage].allowSubdirs &&
          pathWithinSubpackage.contains('/')) {
        problem('Uri $src is in a subfolder of $subpackage, but that '
            'subpackage does not allow dart files in subdirectories.');
      }
      return subpackage;
    }
  
negative.code:   /// Indicates which other subpackages a given subpackage may directly depend
    /// on.
    final List<String> allowedDependencies;
  
    var actuallyContainsFiles = false;
  
    var actuallyImportsAnalyzer = false;
  
    var actuallyHasSubdirs = false;
  
    var actualDependencies = new Set<String>();
  
    SubpackageRules(
        {this.mayImportAnalyzer: false,
  