anchor.diff:      let _, st'' = run_pop ({ st' with repl_env = env }) in
       let status = if peek_only then QueryOK else QueryNOK in
       ((status, JsonList errors), st'')
  +
  +let run_regular_push (st: full_repl_state) query =
  +  let commit_names st name_events =
  +    { st with repl_names = commit_name_tracking st.repl_curmod st.repl_names name_events } in
  +
  +  let do_push st env deps =
  +    run_regular_push_without_deps st env deps query in
  +
  +  let on_failed_init (env, name_events) deps =
  +    let st = { st with repl_env = env; repl_deps = deps } in
  +    handle_deps_failure (commit_names st name_events) in
  +
  +  let on_successful_init (env, name_events) deps =
  +    Options.restore_cmd_line_options false |> ignore;
  +    do_push (commit_names st name_events) env st.repl_deps in
  +
  +  let do_init_then_push st env =
  +    let env, finish_name_tracking = track_name_changes env in // begin name tracking…
  +
  +    match load_deps env st.repl_fname st.repl_deps with
  +    | Inl (env, deps, repl_deps) -> // …end name tracking
  +      on_successful_init (finish_name_tracking env) repl_deps
  +    | Inr (env, completed_tasks) -> // …end name tracking
  +      on_failed_init (finish_name_tracking env) completed_tasks in
  +
  +  let env = push_repl query.push_kind st in
  +  if repl_stack_empty () then
  +    do_init_then_push st env // Update dependencies and restore options
  +  else
  +    do_push st env st.repl_deps
   
   let capitalize str =
     if str = "" then str
  
positive.code:   let rec revert_many env = function
      | [] -> env
      | (task, env') :: entries ->
        debug "Reverting" task;
        pop env' "run_dep_tasks";
        revert_many env' entries in
  
negative.code:   { prepl_env: env_t;
      prepl_fname: string;
      prepl_stdin: stream_reader;
      prepl_names: CompletionTable.table;
      prepl_deps: list<completed_dep_task> }
  
  type full_repl_state = { repl_line: int; repl_column: int; repl_fname: string;
  