diff --git a/src/librustc/ty/print.rs b/src/librustc/ty/print.rs index 569d9d7a3ac..5f46806e159 100644 --- a/src/librustc/ty/print.rs +++ b/src/librustc/ty/print.rs @@ -33,10 +33,9 @@ pub struct PrintContext { impl PrintContext { pub(crate) fn new() -> Self { - ty::tls::with_opt(|tcx| { - let (is_verbose, identify_regions) = tcx.map( - |tcx| (tcx.sess.verbose(), tcx.sess.opts.debugging_opts.identify_regions) - ).unwrap_or((false, false)); + ty::tls::with(|tcx| { + let (is_verbose, identify_regions) = + (tcx.sess.verbose(), tcx.sess.opts.debugging_opts.identify_regions); PrintContext { is_debug: false, is_verbose: is_verbose,