anchor.diff:        if (backendTypeHelpers.contains(cls)) continue;
         while (cls != null && !neededClasses.contains(cls)) {
           if (!classesOnlyNeededForRti.add(cls)) break;
  +        // TODO(joshualitt) delete classesOnlyNeededForRti when the
  +        // no-defer-class_types flag is removed.
  +        neededClassTypes.add(cls);
           cls = _elementEnvironment.getSuperClass(cls);
         }
       }
   
  -    neededClasses.addAll(classesOnlyNeededForRti);
  -
  -    // 5. Finally, sort the classes.
  -    List<ClassEntity> sortedClasses = _sorter.sortClasses(neededClasses);
  -
  -    for (ClassEntity cls in sortedClasses) {
  -      if (classesOnlyNeededForRti.contains(cls)) {
  -        _outputListsForClassType
  -            .putIfAbsent(_outputUnitData.outputUnitForClassType(cls), () => [])
  -            .add(cls);
  -      } else if (_nativeData.isNativeOrExtendsNative(cls) &&
  +    // 5. Sort classes and add them to their respective OutputUnits.
  +    for (ClassEntity cls in _sorter.sortClasses(neededClasses)) {
  +      if (_nativeData.isNativeOrExtendsNative(cls) &&
             !classesOnlyNeededForConstructor.contains(cls)) {
           // For now, native classes and related classes cannot be deferred.
           nativeClassesAndSubclasses.add(cls);
  
positive.code:       outputLibraryLists.putIfAbsent(unit, () => {}).add(library);
      });
      neededClasses.forEach((ClassEntity element) {
        OutputUnit unit = classesOnlyNeededForRti.contains(element)
            ? _outputUnitData.outputUnitForClassType(element)
            : _outputUnitData.outputUnitForClass(element);
        LibraryEntity library = element.library;
        outputLibraryLists.putIfAbsent(unit, () => {}).add(library);
      });
  
negative.code:     neededClasses.addAll(mixinClasses);
  
      // 3. Add classes only needed for their constructors.
      for (var cls in _codegenWorld.constructorReferences) {
        if (neededClasses.add(cls)) {
          classesOnlyNeededForConstructor.add(cls);
        }
      }
  
      // 4. Find all classes needed for rti.
      // It is important that this is the penultimate step, at this point,
  