public static Vector removeNullsInVariablesVector(Vector iovariables) {
    if (!iovariables.memberP(null)) {
      return (iovariables);
    }
    { Cons newvbllist = Stella.NIL;
      Vector result = null;

      { PatternVariable vbl = null;
        Vector vector000 = iovariables;
        int index000 = 0;
        int length000 = vector000.length();
        Cons collect000 = null;

        for (;index000 < length000; index000 = index000 + 1) {
          vbl = ((PatternVariable)((vector000.theArray)[index000]));
          if (vbl != null) {
            if (collect000 == null) {
              {
                collect000 = Cons.cons(vbl, Stella.NIL);
                if (newvbllist == Stella.NIL) {
                  newvbllist = collect000;
                }
                else {
                  Cons.addConsToEndOfConsList(newvbllist, collect000);
                }
              }
            }
            else {
              {
                collect000.rest = Cons.cons(vbl, Stella.NIL);
                collect000 = collect000.rest;
              }
            }
          }
        }
      }
      result = Logic.copyConsListToVariablesVector(newvbllist);
      return (result);
    }
  }