anchor.diff:     * Write the content based information about the given [source].
      */
     void _writeCacheSourceContent(Source source, CacheSourceContentBuilder b) {
  -    String key = _getCacheSourceContentKey(source);
  -    List<int> bytes = b.toBuffer();
  -    storage.put(key, bytes);
  -    // Put into the cache to avoid reading it later.
  -    _sourceContentMap[source] = new CacheSourceContent.fromBuffer(bytes);
  +    if (!_sourceContentMap.containsKey(source)) {
  +      String key = _getCacheSourceContentKey(source);
  +      List<int> bytes = b.toBuffer();
  +      storage.put(key, bytes);
  +      // Put into the cache to avoid reading it later.
  +      _sourceContentMap[source] = new CacheSourceContent.fromBuffer(bytes);
  +    }
     }
   
     /**
  
positive.code:   void _writeCacheSourceContents(LibraryElement library,
        [Set<LibraryElement> writtenLibraries]) {
      Source librarySource = library.source;
      // Do nothing if already cached.
      if (_sourceContentMap.containsKey(librarySource)) {
        return;
      }
      // Stop recursion cycle.
      writtenLibraries ??= new Set<LibraryElement>();
      if (!writtenLibraries.add(library)) {
  
negative.code:       List<Source> closureSources = _getLibraryClosure(librarySource);
        List<LibraryBundleWithId> closureBundles = <LibraryBundleWithId>[];
        for (Source source in closureSources) {
          if (getSourceKind(source) == SourceKind.PART) {
            continue;
          }
  