private void noteCyclic(DiagnosticPosition pos, ClassSymbol c) {
        log.error(pos, "cyclic.inheritance", c);
        for (List<Type> l=types.interfaces(c.type); l.nonEmpty(); l=l.tail)
            l.head = new ErrorType((ClassSymbol)l.head.tsym);
        Type st = types.supertype(c.type);
        if (st.tag == CLASS)
            ((ClassType)c.type).supertype_field = new ErrorType((ClassSymbol)st.tsym);
        c.type = new ErrorType(c);
        c.flags_field |= ACYCLIC;
    }