public static Cons wrapWhereTest(Stella_Object wheretest, Cons actions) {
    if (wheretest != null) {
      return (Cons.cons(Cons.list$(Cons.cons(Stella.SYM_STELLA_WHEN, Cons.cons(wheretest, Cons.cons(actions.concatenate(Stella.NIL, Stella.NIL), Stella.NIL)))), Stella.NIL));
    }
    else {
      return (actions);
    }
  }