File tree Expand file tree Collapse file tree 1 file changed +21
-5
lines changed
compiler/test/dotty/tools/vulpix Expand file tree Collapse file tree 1 file changed +21
-5
lines changed Original file line number Diff line number Diff line change @@ -41,11 +41,27 @@ private static void runMain(String dir) throws Exception {
4141 }
4242
4343 public static void main (String [] args ) throws Exception {
44- BufferedReader stdin = new BufferedReader (new InputStreamReader (System .in ));
44+ BufferedReader stdin = new BufferedReader (new InputStreamReader (System .in ));
4545
46- while (true ) {
47- runMain (stdin .readLine ());
48- System .out .println (MessageEnd );
49- }
46+ while (true ) {
47+ var err = System .err ;
48+ var out = System .out ;
49+ var in = System .in ;
50+ try {
51+ runMain (stdin .readLine ());
52+ }
53+ finally {
54+ if (err != System .err ) {
55+ System .setErr (err );
56+ }
57+ if (out != System .out ) {
58+ System .setOut (out );
59+ }
60+ if (in != System .in ) {
61+ System .setIn (in );
62+ }
63+ System .out .println (MessageEnd );
64+ }
65+ }
5066 }
5167}
You can’t perform that action at this time.
0 commit comments