public static void retractFactsOfInstance(LogicObject self) {
    if (self == null) {
      return;
    }
    { Proposition p = null;
      Cons iter000 = Logic.allFactsOfInstance(self, false, true).theConsList;

      loop000 : for (;!(iter000 == Stella.NIL); iter000 = iter000.rest) {
        p = ((Proposition)(iter000.value));
        if (p.kind == Logic.KWD_FUNCTION) {
          { Skolem skolem = ((Skolem)(p.arguments.last()));

            if (skolem == self) {
              continue loop000;
            }
            if ((skolem != null) &&
                (((Stella_Object)(Stella_Object.accessInContext(skolem.variableValue, skolem.homeContext, false))) != null)) {
              Proposition.unassertProposition(p);
            }
            LogicObject.retractFactsOfInstance(skolem);
          }
        }
        else {
          Proposition.unassertProposition(p);
        }
      }
    }
  }