newMembers = tp.members();
    public Type transformInfo(Symbol sym, Type tp) {        if (sym.isConstructor()) {            Symbol clazz = sym.constructorClass();            if (!(clazz.isClass() && needInterface(clazz))) return tp;            // The symbol is a constructor of a class which needs            // an interface. All its value arguments have to be            // removed.            return removeValueParams(tp);        } else if (sym.isClass() && !sym.isJava()) {            Definitions definitions = global.definitions;            if (sym == definitions.ANY_CLASS) return tp;            Type[] oldParents = tp.parents();            assert oldParents.length > 0 : Debug.show(sym);            for (int i = 1; i < oldParents.length; ++i) {                Symbol oldSym = oldParents[i].symbol();                assert !oldSym.isJava() || oldSym.isInterface() :                    Debug.show(sym) + " <: " + Debug.show(oldSym);            }            Type[] newParents;            Scope newMembers;            if (needInterface(sym)) {                // Before this phase, the symbol is a class, but after                // it will be an interface. Its type has to be changed                // so that:                //                //   1. Java classes are removed from its parents,                //                //   2. only members which will end up in the                //      interface are kept, and private ones are made                //      public and renamed.                sym.flags |= Modifiers.INTERFACE;                Scope.SymbolIterator oldMembersIt =                    new Scope.UnloadIterator(tp.members().iterator());                newMembers = new Scope();                while (oldMembersIt.hasNext()) {                    Symbol member = oldMembersIt.next();                    if (!memberGoesInInterface(member) || member.isInitializer())                        continue;                    if (member.isPrivate()) {                        member.name = uniqueName(member);                        member.flags ^= Modifiers.PRIVATE;                    } else if (member.isProtected())                        member.flags ^= Modifiers.PROTECTED;                    newMembers.enterOrOverload(member);                }                newParents = oldParents;            } else {                // The symbol is the one of a class which doesn't need                // an interface. We need to fix its parents to use                // class symbols instead of interface symbols.                newMembers = tp.members();                newParents = new Type[oldParents.length];                for (int i = 0; i < oldParents.length; ++i) {                    switch (oldParents[i]) {                    case TypeRef(Type pre, Symbol oldSym, Type[] args):                        newParents[i] = !needInterface(oldSym)                            ? oldParents[i]                            : Type.typeRef(pre, getClassSymbol(oldSym), args);                        break;                    default:                        throw Debug.abort("illegal case", oldParents[i]);                    }                }            }            return Type.compoundType(newParents, newMembers, sym);        } else if (sym.isThisSym() && hasInterfaceSymbol(sym.owner())) {            switch (tp) {            case TypeRef(_, _, _):                return sym.owner().nextType();            case CompoundType(Type[] parents, Scope members):                parents = Type.cloneArray(parents);                parents[parents.length - 1] = sym.owner().nextType();                return Type.compoundType(parents, members, tp.symbol());            default:                throw Debug.abort("illegal case", tp +" -- "+ Debug.show(sym));            }        } else            return tp;    }