aboutsummaryrefslogtreecommitdiff
path: root/toplevel
diff options
context:
space:
mode:
authorGuillaume Melquiond2021-02-16 09:02:37 +0100
committerGuillaume Melquiond2021-02-16 09:02:37 +0100
commit31e205ae752c5189143ef9ce87a3536db0cdeb62 (patch)
treeff6c9e169d561ce5da25e85e828f46253ef377f3 /toplevel
parentc0e0e637c61e075f43b73d1ddd8eaa9d79b27561 (diff)
Get rid of the compilation date from the binaries to make them more stable.
Contrarily to the comments, Coq_config.date was not the "release date" but just another "compile date".
Diffstat (limited to 'toplevel')
-rw-r--r--toplevel/coqtop.ml10
1 files changed, 4 insertions, 6 deletions
diff --git a/toplevel/coqtop.ml b/toplevel/coqtop.ml
index 16028be910..13637ef540 100644
--- a/toplevel/coqtop.ml
+++ b/toplevel/coqtop.ml
@@ -18,19 +18,17 @@ let () = at_exit flush_all
let ( / ) = Filename.concat
-let get_version_date () =
+let get_version () =
try
let ch = open_in (Envars.coqlib () / "revision") in
let ver = input_line ch in
let rev = input_line ch in
let () = close_in ch in
- (ver,rev)
- with e when CErrors.noncritical e ->
- (Coq_config.version,Coq_config.date)
+ Printf.sprintf "%s (%s)" ver rev
+ with _ -> Coq_config.version
let print_header () =
- let (ver,rev) = get_version_date () in
- Feedback.msg_info (str "Welcome to Coq " ++ str ver ++ str " (" ++ str rev ++ str ")");
+ Feedback.msg_info (str "Welcome to Coq " ++ str (get_version ()));
flush_all ()