public static List helpGetAssertionStructure(Symbol inst, int depth) {
    Logic.$VISITED_INSTANCES$.push(inst);
    { Module home = ((Module)(inst.homeContext));
      List facts = List.newList();
      List antecedent = List.newList();
      List children = null;

      { Object old$Module$000 = Stella.$MODULE$.get();
        Object old$Context$000 = Stella.$CONTEXT$.get();

        try {
          Native.setSpecial(Stella.$MODULE$, home);
          Native.setSpecial(Stella.$CONTEXT$, ((Module)(Stella.$MODULE$.get())));
          facts = Logic.allFactsOfInstance(Logic.getInstance(inst), false, false);

        } finally {
          Stella.$CONTEXT$.set(old$Context$000);
          Stella.$MODULE$.set(old$Module$000);
        }
      }
      { Proposition fact = null;
        Cons iter000 = facts.theConsList;

        for (;!(iter000 == Stella.NIL); iter000 = iter000.rest) {
          fact = ((Proposition)(iter000.value));
          if ((!Logic.$VISITED_PROPOSITIONS$.memberP(fact)) &&
              ((Logic.$TABOO_OPERATORS$ == null) ||
               (!Logic.$TABOO_OPERATORS$.memberP(fact.operator)))) {
            Logic.$VISITED_PROPOSITIONS$.push(fact);
            { Cons consProp = Proposition.propositionToCons(fact);
              Cons consProps = Stella.NIL;

              if (fact.kind == Logic.KWD_ISA) {
                consProps = Cons.cons(consProp, consProps);
              }
              else if (depth < Logic.$MAX_STRUCTURE_DEPTH$) {
                if (fact.kind == Logic.KWD_FUNCTION) {
                  consProps = Cons.cons(consProp, consProps);
                  if (Stella_Object.isaP(consProp.last(), Logic.SGT_STELLA_NUMBER_WRAPPER)) {
                    { Cons skolemName = ((Cons)(Stella_Object.copyConsTree(consProp))).reverse().rest.reverse();
                      Stella_Object skolemValue = consProp.last();

                      consProps = Cons.cons(Cons.list$(Cons.cons(Logic.SYM_STELLA_ge, Cons.cons(((Cons)(Stella_Object.copyConsTree(skolemName))), Cons.cons(Cons.cons(skolemValue, Stella.NIL), Stella.NIL)))), consProps);
                      consProps = Cons.cons(Cons.list$(Cons.cons(Logic.SYM_STELLA_el, Cons.cons(((Cons)(Stella_Object.copyConsTree(skolemName))), Cons.cons(Cons.cons(skolemValue, Stella.NIL), Stella.NIL)))), consProps);
                    }
                  }
                }
                else {
                  if (!((consProp.value == Logic.SYM_STELLA_e) &&
                      Stella_Object.eqlP(consProp.rest.value, consProp.rest.rest.value))) {
                    consProps = Cons.cons(consProp, consProps);
                  }
                }
              }
              else {
              }
              if (!(consProps == Stella.NIL)) {
                { Cons prop = null;
                  Cons iter001 = consProps;

                  for (;!(iter001 == Stella.NIL); iter001 = iter001.rest) {
                    prop = ((Cons)(iter001.value));
                    antecedent.push(prop);
                  }
                }
                { Stella_Object ele = null;
                  Cons iter002 = consProp.rest;

                  for (;!(iter002 == Stella.NIL); iter002 = iter002.rest) {
                    ele = iter002.value;
                    if (Stella_Object.isaP(ele, Logic.SGT_STELLA_SYMBOL) &&
                        ((!Logic.$VISITED_INSTANCES$.memberP(ele)) &&
                         (depth < Logic.$MAX_STRUCTURE_DEPTH$))) {
                      if (children == null) {
                        children = Logic.helpGetAssertionStructure(((Symbol)(ele)), depth + 1);
                      }
                      else {
                        children = Logic.helpGetAssertionStructure(((Symbol)(ele)), depth + 1).concatenate(children, Stella.NIL);
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
      if (children == null) {
        return (antecedent);
      }
      else {
        return (antecedent.concatenate(children, Stella.NIL));
      }
    }
  }