public static void buildClassificationRule(Symbol kind, Symbol className) {
    { Symbol ruleName = Symbol.internSymbol(kind.symbolName + "-Classification-Rule");
      Symbol relationName = Symbol.internSymbol(kind.symbolName + "-Classification");
      String index = className.symbolName + "-match";
      List ruleAntecedent = ((List)(Logic.$CASE_ANTECEDENT_TABLE$.lookup(index)));
      Cons convertedAntecedent = Stella.NIL;
      List ruleTypes = ((List)(Logic.$CASE_TYPES_TABLE$.lookup(index)));
      Cons convertedTypes = Stella.NIL;
      Cons relation = Cons.list$(Cons.cons(Logic.SYM_LOGIC_DEFRELATION, Cons.cons(relationName, Cons.cons(Cons.cons(Cons.cons(Cons.list$(Cons.cons(Logic.SYM_LOGIC_pP, Cons.cons(Logic.SYM_STELLA_THING, Cons.cons(Stella.NIL, Stella.NIL)))), Stella.NIL), Stella.NIL), Stella.NIL))));
      Cons rule = Stella.NIL;

      { Cons clause = null;
        Cons iter000 = ruleAntecedent.theConsList;
        Cons collect000 = null;

        for (;!(iter000 == Stella.NIL); iter000 = iter000.rest) {
          clause = ((Cons)(iter000.value));
          if (collect000 == null) {
            {
              collect000 = Cons.cons(clause, Stella.NIL);
              if (convertedAntecedent == Stella.NIL) {
                convertedAntecedent = collect000;
              }
              else {
                Cons.addConsToEndOfConsList(convertedAntecedent, collect000);
              }
            }
          }
          else {
            {
              collect000.rest = Cons.cons(clause, Stella.NIL);
              collect000 = collect000.rest;
            }
          }
        }
      }
      { Symbol type = null;
        Cons iter001 = ruleTypes.theConsList;
        Cons collect001 = null;

        for (;!(iter001 == Stella.NIL); iter001 = iter001.rest) {
          type = ((Symbol)(iter001.value));
          if (collect001 == null) {
            {
              collect001 = Cons.cons(type, Stella.NIL);
              if (convertedTypes == Stella.NIL) {
                convertedTypes = collect001;
              }
              else {
                Cons.addConsToEndOfConsList(convertedTypes, collect001);
              }
            }
          }
          else {
            {
              collect001.rest = Cons.cons(type, Stella.NIL);
              collect001 = collect001.rest;
            }
          }
        }
      }
      rule = Cons.list$(Cons.cons(Logic.SYM_LOGIC_DEFRULE, Cons.cons(ruleName, Cons.cons(Cons.list$(Cons.cons(Cons.list$(Cons.cons(Logic.SYM_STELLA_FORALL, Cons.cons(convertedTypes, Cons.cons(Cons.cons(Cons.list$(Cons.cons(Logic.SYM_STELLA_eg, Cons.cons(Cons.cons(Logic.SYM_STELLA_AND, convertedAntecedent.concatenate(Stella.NIL, Stella.NIL)), Cons.cons(Cons.cons(relationName, Cons.cons(Logic.SYM_LOGIC_pY, Stella.NIL)), Cons.cons(Stella.NIL, Stella.NIL))))), Stella.NIL), Stella.NIL)))), Cons.cons(Logic.KWD_DONT_OPTIMIZEp, Cons.cons(Logic.SYM_STELLA_TRUE, Cons.cons(Stella.NIL, Stella.NIL))))), Stella.NIL))));
      if (Logic.$LOG_MATCH_RULES$) {
        System.out.println(rule);
      }
      System.out.println("Building classification rule with " + convertedAntecedent.length() + " clauses and " + convertedTypes.length() + " variables");
      if (!ruleAntecedent.emptyP()) {
        Logic.evaluateLogicCommand(relation, false);
        Logic.evaluateLogicCommand(rule, false);
      }
    }
  }