Use generic NonZero internally.
This commit is contained in:
@@ -16,6 +16,7 @@
|
||||
#![feature(box_patterns)]
|
||||
#![feature(error_reporter)]
|
||||
#![feature(extract_if)]
|
||||
#![feature(generic_nonzero)]
|
||||
#![feature(let_chains)]
|
||||
#![feature(negative_impls)]
|
||||
#![feature(never_type)]
|
||||
@@ -77,7 +78,7 @@ use std::error::Report;
|
||||
use std::fmt;
|
||||
use std::hash::Hash;
|
||||
use std::io::Write;
|
||||
use std::num::NonZeroUsize;
|
||||
use std::num::NonZero;
|
||||
use std::ops::DerefMut;
|
||||
use std::panic;
|
||||
use std::path::{Path, PathBuf};
|
||||
@@ -545,7 +546,7 @@ pub struct DiagCtxtFlags {
|
||||
pub can_emit_warnings: bool,
|
||||
/// If Some, the Nth error-level diagnostic is upgraded to bug-level.
|
||||
/// (rustc: see `-Z treat-err-as-bug`)
|
||||
pub treat_err_as_bug: Option<NonZeroUsize>,
|
||||
pub treat_err_as_bug: Option<NonZero<usize>>,
|
||||
/// Eagerly emit delayed bugs as errors, so that the compiler debugger may
|
||||
/// see all of the errors being emitted at once.
|
||||
pub eagerly_emit_delayed_bugs: bool,
|
||||
|
||||
Reference in New Issue
Block a user