println("    if (peer instanceof " + className(alt) + ") {");
println("    if (peer instanceof " + className(type,alt) + ") {");
    private void genAltEquivalentMethod(Type type, Alternative alt) {        println("  public boolean equivalent(shared.SharedObject peer) {");        println("    if (peer instanceof " + className(alt) + ") {");        println("      return super.equivalent(peer);");        println("    }");        println("    return false;");        println("  }");        println();    }