Skip to content

Commit db1719f

Browse files
committed
[ide] Remove special option -ideslave
This has no effect anymore, verbose printing is controlled now by the regular, common `quiet` flag.
1 parent 382ee49 commit db1719f

File tree

11 files changed

+15
-26
lines changed

11 files changed

+15
-26
lines changed

Makefile.build

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -504,7 +504,7 @@ $(COQWORKMGR): $(call bestobj, clib/clib.cma lib/lib.cma stm/spawned.cmo stm/coq
504504
$(HIDE)$(call bestocaml, $(SYSMOD))
505505

506506
# fake_ide : for debugging or test-suite purpose, a fake ide simulating
507-
# a connection to coqtop -ideslave
507+
# a connection to coqidetop
508508

509509
FAKEIDECMO:=clib/clib.cma lib/lib.cma ide/document.cmo \
510510
ide/serialize.cmo ide/xml_lexer.cmo ide/xml_parser.cmo \

Makefile.ide

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ COQIDEINAPP:=$(COQIDEAPP)/Contents/MacOS/coqide
3636

3737
# Note : for just building bin/coqide, we could only consider
3838
# config, lib, ide and ide/utils. But the coqidetop plugin (the
39-
# one that will be loaded by coqtop -ideslave) refers to some
39+
# one that will be loaded by coqidetop) refers to some
4040
# core modules of coq, for instance printing/*.
4141

4242
IDESRCDIRS:= $(CORESRCDIRS) ide ide/utils

ide/coq.ml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ let print_status = function
152152
let check_connection args =
153153
let lines = ref [] in
154154
let argstr = String.concat " " (List.map Filename.quote args) in
155-
let cmd = Filename.quote (coqtop_path ()) ^ " -batch -ideslave " ^ argstr in
155+
let cmd = Filename.quote (coqtop_path ()) ^ " -batch " ^ argstr in
156156
let cmd = requote cmd in
157157
try
158158
let oc,ic,ec = Unix.open_process_full cmd (Unix.environment ()) in
@@ -377,7 +377,7 @@ let spawn_handle args respawner feedback_processor =
377377
else
378378
"on"
379379
in
380-
let args = Array.of_list ("--xml_format=Ppcmds" :: "-async-proofs" :: async_default :: "-ideslave" :: args) in
380+
let args = Array.of_list ("--xml_format=Ppcmds" :: "-async-proofs" :: async_default :: args) in
381381
let env =
382382
match !ideslave_coqtop_flags with
383383
| None -> None

ide/idetop.ml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,8 @@ open Printer
1818
module NamedDecl = Context.Named.Declaration
1919
module CompactedDecl = Context.Compacted.Declaration
2020

21-
(** Ide_slave : an implementation of [Interface], i.e. mainly an interp
22-
function and a rewind function. This specialized loop is triggered
23-
when the -ideslave option is passed to Coqtop. *)
21+
(** Idetop : an implementation of [Interface], i.e. mainly an interp
22+
function and a rewind function. *)
2423

2524

2625
(** Signal handling: we postpone ^C during input and output phases,
@@ -429,7 +428,7 @@ let eval_call c =
429428
Xmlprotocol.abstract_eval_call handler c
430429

431430
(** Message dispatching.
432-
Since coqtop -ideslave starts 1 thread per slave, and each
431+
Since [coqidetop] starts 1 thread per slave, and each
433432
thread forwards feedback messages from the slave to the GUI on the same
434433
xml channel, we need mutual exclusion. The mutex should be per-channel, but
435434
here we only use 1 channel. *)

lib/flags.ml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,6 @@ let in_toplevel = ref false
5757

5858
let profile = false
5959

60-
let ide_slave = ref false
61-
6260
let raw_print = ref false
6361

6462
let we_are_parsing = ref false

lib/flags.mli

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,9 +52,6 @@ val in_toplevel : bool ref
5252

5353
val profile : bool
5454

55-
(* -ide_slave: printing will be more verbose, will affect stm caching *)
56-
val ide_slave : bool ref
57-
5855
(* development flag to detect race conditions, it should go away. *)
5956
val we_are_parsing : bool ref
6057

lib/stateid.ml

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,11 @@
1111
type t = int
1212
let initial = 1
1313
let dummy = 0
14-
let fresh, in_range =
14+
let fresh =
1515
let cur = ref initial in
16-
(fun () -> incr cur; !cur), (fun id -> id >= 0 && id <= !cur)
16+
fun () -> incr cur; !cur
1717
let to_string = string_of_int
18-
let of_int id =
19-
(* Coqide too to parse ids too, but cannot check if they are valid.
20-
* Hence we check for validity only if we are an ide slave. *)
21-
if !Flags.ide_slave then assert (in_range id);
22-
id
18+
let of_int id = id
2319
let to_int id = id
2420
let newer_than id1 id2 = id1 > id2
2521

stm/asyncTaskQueue.ml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ module Make(T : Task) () = struct
123123
["-worker-id"; name;
124124
"-async-proofs-worker-priority";
125125
CoqworkmgrApi.(string_of_priority !async_proofs_worker_priority)]
126-
| ("-ideslave"|"-emacs"|"-emacs-U"|"-batch")::tl -> set_slave_opt tl
126+
| ("-emacs"|"-emacs-U"|"-batch")::tl -> set_slave_opt tl
127127
| ("-async-proofs" |"-vio2vo"
128128
|"-load-vernac-source" |"-l" |"-load-vernac-source-verbose" |"-lv"
129129
|"-compile" |"-compile-verbose"

tools/fake_ide.ml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
(* * (see LICENSE file for the text of the license) *)
99
(************************************************************************)
1010

11-
(** Fake_ide : Simulate a [coqide] talking to a [coqtop -ideslave] *)
11+
(** Fake_ide : Simulate a [coqide] talking to a [coqidetop] *)
1212

1313
let error s =
1414
prerr_endline ("fake_id: error: "^s);
@@ -284,7 +284,7 @@ let read_command inc = Parser.parse grammar inc
284284

285285
let usage () =
286286
error (Printf.sprintf
287-
"A fake coqide process talking to a coqtop -ideslave.\n\
287+
"A fake coqide process talking to a coqtop -toploop coqidetop.\n\
288288
Usage: %s (file|-) [<coqtop>]\n\
289289
Input syntax is the following:\n%s\n"
290290
(Filename.basename Sys.argv.(0))
@@ -296,7 +296,7 @@ let main =
296296
if Sys.os_type = "Unix" then Sys.set_signal Sys.sigpipe
297297
(Sys.Signal_handle
298298
(fun _ -> prerr_endline "Broken Pipe (coqtop died ?)"; exit 1));
299-
let def_args = ["--xml_format=Ppcmds"; "-ideslave"] in
299+
let def_args = ["--xml_format=Ppcmds"] in
300300
let idetop_name = System.get_toplevel_path "coqidetop" in
301301
let coqtop_args, input_file = match Sys.argv with
302302
| [| _; f |] -> Array.of_list def_args, f

toplevel/coqargs.ml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -529,7 +529,6 @@ let parse_args arglist : coq_cmdopts * string list =
529529
|"-stm-debug" -> Stm.stm_debug := true; oval
530530
|"-emacs" -> set_emacs oval
531531
|"-filteropts" -> { oval with filter_opts = true }
532-
|"-ideslave" -> Flags.ide_slave := true; oval
533532
|"-impredicative-set" ->
534533
{ oval with impredicative_set = Declarations.ImpredicativeSet }
535534
|"-indices-matter" -> Indtypes.enforce_indices_matter (); oval

0 commit comments

Comments
 (0)