anchor.diff:    let check_success () =
       get_err_count () = 0 && not must_rollback in
   
  +  let sigint_handler =
  +    // Ideally we'd want everything to be interruptible, but in practice the
  +    // code in Typechecker.Tc does not ensure that each ‘push_context’ in
  +    // ‘finish_partial_modul’ is always followed by a corresponding
  +    // ‘pop_context’ (that's only true if no exceptions occur).
  +    match task with
  +    | PushFragment _ -> Util.sigint_raise
  +    | _ -> Util.sigint_ignore in
  +
     // Run the task (and capture errors)
     let curmod, env, success =
  -    match with_captured_errors env
  -            (fun env -> Some <| run_repl_task st.repl_curmod env task) with
  +    match with_captured_errors env sigint_handler
  +              (fun env -> Some <| run_repl_task st.repl_curmod env task) with
       | Some (curmod, env) when check_success () -> curmod, env, true
       | _ -> st.repl_curmod, env, false in
   
  
positive.code:   match !repl_stack with
    | [] -> failwith "Too many pops"
    | (_, st') :: stack ->
      pop st.repl_env "#pop";
      repl_stack := stack;
      st'
  
  let push_repl push_kind task st =
    repl_stack := (task, st) :: !repl_stack;
    push (set_check_kind st.repl_env push_kind) ""
  
  (** Check whether users can issue further ``pop`` commands. **)
  let nothing_left_to_pop st =
  
negative.code: //        (k ^ ": " ^ (sigelt_to_string v)) :: acc) []
  //   |> Util.concat_l "\n"
  
  let run_and_rewind st sigint_default task =
    let env' = push st.repl_env "REPL run_and_rewind" in
    let results =
      try Util.with_sigint_handler Util.sigint_raise (fun _ -> Inl <| task st)
      with | Util.SigInt -> Inl sigint_default
           | e -> Inr e in
    pop env' "REPL run_and_rewind";
    match results with
    | Inl results -> (results, Inl ({ st with repl_env = env' }))
    | Inr e -> raise e
  