public static Cons finishWalkingEqlTree(Cons tree, Surrogate type1, Surrogate type2, Object [] MV_returnarray) {
    if (Surrogate.subtypeOfP(type1, Stella.SGT_STELLA_STANDARD_OBJECT) ||
        (Surrogate.subtypeOfP(type2, Stella.SGT_STELLA_STANDARD_OBJECT) ||
         (((type1 == Stella.SGT_STELLA_BOOLEAN_WRAPPER) &&
        (type2 == Stella.SGT_STELLA_BOOLEAN_WRAPPER)) ||
          (((!Surrogate.subtypeOfP(type1, Stella.SGT_STELLA_OBJECT)) &&
        (!Surrogate.subtypeOfP(type1, Stella.SGT_STELLA_LITERAL))) ||
           ((!Surrogate.subtypeOfP(type2, Stella.SGT_STELLA_OBJECT)) &&
            (!Surrogate.subtypeOfP(type2, Stella.SGT_STELLA_LITERAL))))))) {
      tree.firstSetter(Stella.SYM_STELLA_EQp);
      tree.secondSetter(Stella_Object.sysTree(tree.rest.value, type1, new Object[1]));
      tree.thirdSetter(Stella_Object.sysTree(tree.rest.rest.value, type2, new Object[1]));
      { Cons _return_temp = tree;

        MV_returnarray[0] = Stella.SGT_STELLA_BOOLEAN;
        return (_return_temp);
      }
    }
    if (Surrogate.subtypeOfP(type1, Stella.SGT_STELLA_LITERAL) &&
        Surrogate.subtypeOfP(type2, Stella.SGT_STELLA_LITERAL)) {
      if (type1 == Stella.SGT_STELLA_STRING) {
        tree.firstSetter(Stella.SYM_STELLA_STRING_EQLp);
      }
      else {
        tree.firstSetter(Stella.SYM_STELLA_EQp);
      }
      return (Cons.walkAConsTree(tree, MV_returnarray));
    }
    if ((!Surrogate.subtypeOfP(type1, Stella.SGT_STELLA_LITERAL)) &&
        (!Surrogate.subtypeOfP(type2, Stella.SGT_STELLA_LITERAL))) {
      { Stella_Object otree = null;
        StandardObject otype = null;

        { Object [] caller_MV_returnarray = new Object[1];

          otree = Cons.walkCallSlotTree(tree, caller_MV_returnarray);
          otype = ((StandardObject)(caller_MV_returnarray[0]));
        }
        { Cons _return_temp = ((Cons)(otree));

          MV_returnarray[0] = otype;
          return (_return_temp);
        }
      }
    }
    if (!Surrogate.subtypeOfP(type2, Stella.SGT_STELLA_LITERAL)) {
      { Stella_Object temparg = tree.rest.rest.value;
        Surrogate temptype = type2;

        tree.thirdSetter(tree.rest.value);
        tree.secondSetter(temparg);
        type2 = type1;
        type1 = temptype;
      }
    }
    if (type2 == Stella.SGT_STELLA_BOOLEAN) {
      tree.firstSetter(Stella.SYM_STELLA_EQL_TO_BOOLEANp);
    }
    else if (type2 == Stella.SGT_STELLA_INTEGER) {
      tree.firstSetter(Stella.SYM_STELLA_EQL_TO_INTEGERp);
    }
    else if (type2 == Stella.SGT_STELLA_LONG_INTEGER) {
      tree.firstSetter(Stella.SYM_STELLA_EQL_TO_LONG_INTEGERp);
    }
    else if (type2 == Stella.SGT_STELLA_FLOAT) {
      tree.firstSetter(Stella.SYM_STELLA_EQL_TO_FLOATp);
    }
    else if (type2 == Stella.SGT_STELLA_STRING) {
      tree.firstSetter(Stella.SYM_STELLA_EQL_TO_STRINGp);
    }
    else {
      { OutputStringStream stream000 = OutputStringStream.newOutputStringStream();

        stream000.nativeStream.print("`" + type2 + "' is not a valid case option");
        throw ((StellaException)(StellaException.newStellaException(stream000.theStringReader()).fillInStackTrace()));
      }
    }
    { Cons _return_temp = ((Cons)(Stella_Object.walkWithoutTypeTree(tree)));

      MV_returnarray[0] = Stella.SGT_STELLA_BOOLEAN;
      return (_return_temp);
    }
  }