From fb0caf14daff2e433dfc33ca564d49b26f7e8fb4 Mon Sep 17 00:00:00 2001 From: Emilio Jesus Gallego Arias Date: Mon, 18 May 2020 22:12:29 +0200 Subject: [topfmt] Set formatter + flush fix Closes #12351. We set the parameters of the redirect formatter to be same than the ones in stdout. I guess the original semantics was to ignore the parameters, so I'm unsure we want to do this. While we are a it, we include a fix on the formatter, which _must_ be flushed before closing its associated channel. --- test-suite/misc/redirect_printing.out | 2 ++ test-suite/misc/redirect_printing.sh | 4 ++++ test-suite/misc/redirect_printing.v | 2 ++ 3 files changed, 8 insertions(+) create mode 100644 test-suite/misc/redirect_printing.out create mode 100755 test-suite/misc/redirect_printing.sh create mode 100644 test-suite/misc/redirect_printing.v (limited to 'test-suite/misc') diff --git a/test-suite/misc/redirect_printing.out b/test-suite/misc/redirect_printing.out new file mode 100644 index 0000000000..4f45c4d4c2 --- /dev/null +++ b/test-suite/misc/redirect_printing.out @@ -0,0 +1,2 @@ +nat_ind + : forall P : nat -> Prop, P 0 -> (forall n : nat, P n -> P (S n)) -> forall n : nat, P n diff --git a/test-suite/misc/redirect_printing.sh b/test-suite/misc/redirect_printing.sh new file mode 100755 index 0000000000..7da17407f3 --- /dev/null +++ b/test-suite/misc/redirect_printing.sh @@ -0,0 +1,4 @@ +#!/usr/bin/env bash + +$coqc misc/redirect_printing.v +diff -u redirect_test.out misc/redirect_printing.out diff --git a/test-suite/misc/redirect_printing.v b/test-suite/misc/redirect_printing.v new file mode 100644 index 0000000000..2f9096bcb8 --- /dev/null +++ b/test-suite/misc/redirect_printing.v @@ -0,0 +1,2 @@ +Set Printing Width 999999. +Redirect "redirect_test" Check nat_ind. -- cgit v1.2.3