File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -121,7 +121,6 @@ impl<'a> JobState<'a> {
121121 /// This should only be called once because a metadata file can only be
122122 /// produced once!
123123 pub fn rmeta_produced ( & self ) {
124- assert ! ( self . rmeta_required. get( ) ) ;
125124 self . rmeta_required . set ( false ) ;
126125 let _ = self
127126 . tx
Original file line number Diff line number Diff line change @@ -698,10 +698,11 @@ fn add_error_format_and_color(
698698 // prettily, and then when parsing JSON messages from rustc we need to
699699 // internally understand that we should extract the `rendered` field and
700700 // present it if we can.
701- if cx. bcx . build_config . cache_messages ( ) || pipelined {
701+ let wants_artifacts = pipelined || cx. bcx . config . cli_unstable ( ) . timings . is_some ( ) ;
702+ if cx. bcx . build_config . cache_messages ( ) || wants_artifacts {
702703 cmd. arg ( "--error-format=json" ) ;
703704 let mut json = String :: from ( "--json=diagnostic-rendered-ansi" ) ;
704- if pipelined {
705+ if wants_artifacts {
705706 json. push_str ( ",artifacts" ) ;
706707 }
707708 match cx. bcx . build_config . message_format {
@@ -1075,7 +1076,8 @@ struct OutputOptions {
10751076
10761077impl OutputOptions {
10771078 fn new < ' a > ( cx : & Context < ' a , ' _ > , unit : & Unit < ' a > ) -> OutputOptions {
1078- let look_for_metadata_directive = cx. rmeta_required ( unit) ;
1079+ let look_for_metadata_directive =
1080+ cx. rmeta_required ( unit) || cx. bcx . config . cli_unstable ( ) . timings . is_some ( ) ;
10791081 let color = cx. bcx . config . shell ( ) . supports_color ( ) ;
10801082 let cache_cell = if cx. bcx . build_config . cache_messages ( ) {
10811083 let path = cx. files ( ) . message_cache_path ( unit) ;
You can’t perform that action at this time.
0 commit comments