anchor.diff:      //      }
       //    }
       //  }
  -    final CoreTypes coreTypes = typeContext.typeEnvironment.coreTypes;
  +    //
  +    // and:
  +    //
  +    //   await for ({var/final} T <variable> in <stream>) { ... }
  +    //
  +    // Into
  +    //
  +    //  {
  +    //    final StreamIterator<T> #forIterator = StreamIterator(<stream>);
  +    //    for (; await #forIterator.moveNext() ;) {
  +    //        {var/final} T variable = await #forIterator.current;
  +    //        ...
  +    //      }
  +    //    }
  +    //  }
   
       // The CFE might invoke this transformation despite the program having
       // compile-time errors. So we will not transform this [stmt] if the
  
positive.code:     return super.visitClass(cls);
    }
  
    @override
    TreeNode visitForInStatement(ForInStatement stmt) {
      // Transform
      //
      //   for ({var/final} T <variable> in <iterable>) { ... }
  
negative.code:           InvalidExpression('Invalid iterable type in for-in'));
      }
  
      final isAsync = stmt.isAsync;
      late final Class iteratorClass;
      late final Procedure iteratorMoveNext;
      late final Member iteratorCurrent;
      if (isAsync) {
        iteratorClass = coreTypes.streamIteratorClass;
        iteratorMoveNext = coreTypes.streamIteratorMoveNext;
        iteratorCurrent = coreTypes.streamIteratorCurrent;
      } else {
        iteratorClass = coreTypes.iteratorClass;
        iteratorMoveNext = coreTypes.iteratorMoveNext;
        iteratorCurrent = coreTypes.iteratorGetCurrent;
      }
  
      final DartType elementType = stmt.getElementType(typeContext);
      final iteratorType =
          InterfaceType(iteratorClass, Nullability.nonNullable, [elementType]);
  
      late final Expression iteratorInitializer;
      if (isAsync) {
        iteratorInitializer = ConstructorInvocation(
            coreTypes.streamIteratorDefaultConstructor,
            Arguments([iterable], types: [elementType]));
      } else {
        iteratorInitializer = InstanceGet(
            InstanceAccessKind.Instance, iterable, Name('iterator'),
            interfaceTarget: coreTypes.iterableGetIterator,
            resultType: iteratorType);
      }
  
      final iterator = VariableDeclaration("#forIterator",
          initializer: iteratorInitializer..fileOffset = iterable.fileOffset,
          type: iteratorType)
        ..fileOffset = iterable.fileOffset;
  
      final condition = InstanceInvocation(InstanceAccessKind.Instance,
          VariableGet(iterator), Name('moveNext'), Arguments(const []),
          interfaceTarget: iteratorMoveNext,
          functionType: iteratorMoveNext.getterType as FunctionType)
        ..fileOffset = iterable.fileOffset;
  
      final variable = stmt.variable
        ..initializer = (InstanceGet(
            InstanceAccessKind.Instance, VariableGet(iterator), Name('current'),
            interfaceTarget: iteratorCurrent, resultType: elementType)
          ..fileOffset = stmt.bodyOffset);
  
      final Block body = Block([variable, stmt.body])
        ..fileOffset = stmt.fileOffset;
  
      return Block([
        iterator,
        ForStatement(const [], isAsync ? AwaitExpression(condition) : condition,
            const [], body)
      ]).accept<TreeNode>(this);
    }
  
    @override
    TreeNode visitForInStatement(ForInStatement stmt) {
      return _lowerForIn(stmt);
    }
  }
  