anchor.diff:      // If the set of directly referenced files of this file is changed,
       // then the transitive sets of files that include this file are also
       // changed. Reset these transitive sets.
  -    if (_directReferencedFiles.length != oldDirectReferencedFiles.length ||
  -        !_directReferencedFiles.containsAll(oldDirectReferencedFiles)) {
  -      for (FileState file in _fsState._uriToFile.values) {
  -        if (file._transitiveFiles != null &&
  -            file._transitiveFiles.contains(this)) {
  -          file._transitiveFiles = null;
  +    if (oldDirectReferencedFiles != null) {
  +      if (_directReferencedFiles.length != oldDirectReferencedFiles.length ||
  +          !_directReferencedFiles.containsAll(oldDirectReferencedFiles)) {
  +        for (FileState file in _fsState._uriToFile.values) {
  +          if (file._transitiveFiles != null &&
  +              file._transitiveFiles.contains(this)) {
  +            file._transitiveFiles = null;
  +          }
           }
         }
       }
  
positive.code:   List<FileState> _libraryFiles;
    List<NameFilter> _exportFilters;
  
    Set<FileState> _directReferencedFiles = new Set<FileState>();
    Set<FileState> _transitiveFiles;
    String _transitiveSignature;
  
  
negative.code: 
        void appendReferenced(FileState file) {
          if (_transitiveFiles.add(file)) {
            file._directReferencedFiles?.forEach(appendReferenced);
          }
        }
  
  