File tree 2 files changed +5
-2
lines changed
librustc_mir/borrow_check/nll/region_infer 2 files changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -437,6 +437,9 @@ impl Session {
437
437
pub fn print_llvm_passes ( & self ) -> bool {
438
438
self . opts . debugging_opts . print_llvm_passes
439
439
}
440
+ pub fn nll_dump_cause ( & self ) -> bool {
441
+ self . opts . debugging_opts . nll_dump_cause
442
+ }
440
443
pub fn emit_end_regions ( & self ) -> bool {
441
444
self . opts . debugging_opts . emit_end_regions ||
442
445
( self . opts . debugging_opts . mir_emit_validate > 0 ) ||
Original file line number Diff line number Diff line change @@ -248,7 +248,7 @@ impl<'tcx> RegionInferenceContext<'tcx> {
248
248
. map ( |origin| RegionDefinition :: new ( origin) )
249
249
. collect ( ) ;
250
250
251
- let nll_dump_cause = ty:: tls:: with ( |tcx| tcx. sess . opts . debugging_opts . nll_dump_cause ) ;
251
+ let nll_dump_cause = ty:: tls:: with ( |tcx| tcx. sess . nll_dump_cause ( ) ) ;
252
252
253
253
let mut result = Self {
254
254
definitions,
@@ -1259,7 +1259,7 @@ impl Cause {
1259
1259
pub ( crate ) fn label_diagnostic ( & self , mir : & Mir < ' _ > , diag : & mut DiagnosticBuilder < ' _ > ) {
1260
1260
// The cause information is pretty messy. Only dump it as an
1261
1261
// internal debugging aid if -Znll-dump-cause is given.
1262
- let nll_dump_cause = ty:: tls:: with ( |tcx| tcx. sess . opts . debugging_opts . nll_dump_cause ) ;
1262
+ let nll_dump_cause = ty:: tls:: with ( |tcx| tcx. sess . nll_dump_cause ( ) ) ;
1263
1263
if !nll_dump_cause {
1264
1264
return ;
1265
1265
}
You can’t perform that action at this time.
0 commit comments