From 8df39667dcc802a152ca0fe0b85e51a7b6788b82 Mon Sep 17 00:00:00 2001 From: Mahdi Dibaiee Date: Thu, 20 Jul 2023 16:47:42 +0100 Subject: new unstable option: -Zwrite-long-types-to-disk This option guards the logic of writing long type names in files and instead using short forms in error messages in rustc_middle/ty/error behind a flag. The main motivation for this change is to disable this behaviour when running ui tests. This logic can be triggered by running tests in a directory that has a long enough path, e.g. /my/very-long-path/where/rust-codebase/exists/ This means ui tests can fail depending on how long the path to their file is. Some ui tests actually rely on this behaviour for their assertions, so for those we enable the flag manually. --- compiler/rustc_interface/src/tests.rs | 1 + 1 file changed, 1 insertion(+) (limited to 'compiler/rustc_interface/src/tests.rs') diff --git a/compiler/rustc_interface/src/tests.rs b/compiler/rustc_interface/src/tests.rs index 09141afd137..20171f72c41 100644 --- a/compiler/rustc_interface/src/tests.rs +++ b/compiler/rustc_interface/src/tests.rs @@ -738,6 +738,7 @@ fn test_unstable_options_tracking_hash() { untracked!(unstable_options, true); untracked!(validate_mir, true); untracked!(verbose, true); + untracked!(write_long_types_to_disk, true); // tidy-alphabetical-end macro_rules! tracked { -- cgit 1.4.1-3-g733a5