Rollup merge of #129767 - nnethercote:rm-extern-crate-tracing-4, r=jieyouxu
Remove `#[macro_use] extern crate tracing`, round 4 Because explicit importing of macros via use items is nicer (more standard and readable) than implicit importing via #[macro_use]. Continuing the work from #124511, #124914, and #125434. After this PR no `rustc_*` crates use `#[macro_use] extern crate tracing` except for `rustc_codegen_gcc` which is a special case and I will do separately. r? ```@jieyouxu```
This commit is contained in:
@@ -9,6 +9,7 @@ use rustc_data_structures::unord::UnordSet;
|
||||
use rustc_infer::infer::DefineOpaqueTypes;
|
||||
use rustc_middle::mir::interpret::ErrorHandled;
|
||||
use rustc_middle::ty::{Region, RegionVid};
|
||||
use tracing::debug;
|
||||
|
||||
use super::*;
|
||||
use crate::errors::UnableToConstructConstantValue;
|
||||
|
||||
@@ -21,6 +21,7 @@ use rustc_middle::ty::{self, Ty, TyCtxt};
|
||||
pub use rustc_next_trait_solver::coherence::*;
|
||||
use rustc_span::symbol::sym;
|
||||
use rustc_span::{Span, DUMMY_SP};
|
||||
use tracing::{debug, instrument, warn};
|
||||
|
||||
use super::ObligationCtxt;
|
||||
use crate::error_reporting::traits::suggest_new_overflow_limit;
|
||||
|
||||
@@ -17,6 +17,7 @@ use rustc_middle::traits::ObligationCause;
|
||||
use rustc_middle::ty::abstract_const::NotConstEvaluatable;
|
||||
use rustc_middle::ty::{self, TyCtxt, TypeVisitable, TypeVisitableExt, TypeVisitor};
|
||||
use rustc_span::{Span, DUMMY_SP};
|
||||
use tracing::{debug, instrument};
|
||||
|
||||
use crate::traits::ObligationCtxt;
|
||||
|
||||
|
||||
@@ -13,6 +13,7 @@ use rustc_middle::mir::interpret::ErrorHandled;
|
||||
use rustc_middle::ty::abstract_const::NotConstEvaluatable;
|
||||
use rustc_middle::ty::error::{ExpectedFound, TypeError};
|
||||
use rustc_middle::ty::{self, Binder, Const, GenericArgsRef, TypeVisitableExt};
|
||||
use tracing::{debug, debug_span, instrument};
|
||||
|
||||
use super::project::{self, ProjectAndUnifyResult};
|
||||
use super::select::SelectionContext;
|
||||
|
||||
@@ -37,6 +37,7 @@ use rustc_middle::ty::{
|
||||
};
|
||||
use rustc_span::def_id::DefId;
|
||||
use rustc_span::Span;
|
||||
use tracing::{debug, instrument};
|
||||
|
||||
pub use self::coherence::{
|
||||
add_placeholder_note, orphan_check_trait_ref, overlapping_impls, InCrate, IsFirstInputType,
|
||||
|
||||
@@ -11,6 +11,7 @@ use rustc_middle::traits::{ObligationCause, ObligationCauseCode, Reveal};
|
||||
use rustc_middle::ty::{
|
||||
self, Ty, TyCtxt, TypeFoldable, TypeFolder, TypeSuperFoldable, TypeVisitable, TypeVisitableExt,
|
||||
};
|
||||
use tracing::{debug, instrument};
|
||||
|
||||
use super::{
|
||||
project, with_replaced_escaping_bound_vars, BoundVarReplacer, PlaceholderReplacer,
|
||||
|
||||
@@ -24,6 +24,7 @@ use rustc_span::symbol::Symbol;
|
||||
use rustc_span::Span;
|
||||
use rustc_target::abi::Abi;
|
||||
use smallvec::SmallVec;
|
||||
use tracing::{debug, instrument};
|
||||
|
||||
use super::elaborate;
|
||||
use crate::infer::TyCtxtInferExt;
|
||||
|
||||
@@ -7,6 +7,7 @@ use rustc_middle::span_bug;
|
||||
pub use rustc_middle::traits::query::OutlivesBound;
|
||||
use rustc_middle::ty::{self, ParamEnv, Ty, TypeFolder, TypeVisitableExt};
|
||||
use rustc_span::def_id::LocalDefId;
|
||||
use tracing::{debug, instrument};
|
||||
|
||||
use crate::infer::InferCtxt;
|
||||
use crate::traits::{ObligationCause, ObligationCtxt};
|
||||
|
||||
@@ -18,6 +18,7 @@ use rustc_middle::ty::visit::{MaxUniverse, TypeVisitable, TypeVisitableExt};
|
||||
use rustc_middle::ty::{self, Term, Ty, TyCtxt, Upcast};
|
||||
use rustc_middle::{bug, span_bug};
|
||||
use rustc_span::symbol::sym;
|
||||
use tracing::{debug, instrument};
|
||||
|
||||
use super::{
|
||||
specialization_graph, translate_args, util, MismatchedProjectionTypes, Normalized,
|
||||
|
||||
@@ -2,6 +2,7 @@ use rustc_data_structures::fx::FxHashSet;
|
||||
use rustc_middle::traits::query::{DropckConstraint, DropckOutlivesResult};
|
||||
use rustc_middle::ty::{self, EarlyBinder, ParamEnvAnd, Ty, TyCtxt};
|
||||
use rustc_span::{Span, DUMMY_SP};
|
||||
use tracing::{debug, instrument};
|
||||
|
||||
use crate::traits::query::normalize::QueryNormalizeExt;
|
||||
use crate::traits::query::NoSolution;
|
||||
|
||||
@@ -10,6 +10,7 @@ use rustc_middle::ty::fold::{FallibleTypeFolder, TypeFoldable, TypeSuperFoldable
|
||||
use rustc_middle::ty::visit::{TypeSuperVisitable, TypeVisitable, TypeVisitableExt};
|
||||
use rustc_middle::ty::{self, Ty, TyCtxt, TypeVisitor};
|
||||
use rustc_span::DUMMY_SP;
|
||||
use tracing::{debug, info, instrument};
|
||||
|
||||
use super::NoSolution;
|
||||
use crate::error_reporting::traits::OverflowCause;
|
||||
|
||||
@@ -5,6 +5,7 @@ use rustc_middle::traits::query::NoSolution;
|
||||
use rustc_middle::traits::{ObligationCause, ObligationCauseCode};
|
||||
use rustc_middle::ty::{self, ParamEnvAnd, Ty, TyCtxt, UserArgs, UserSelfTy, UserType};
|
||||
use rustc_span::{Span, DUMMY_SP};
|
||||
use tracing::{debug, instrument};
|
||||
|
||||
use crate::infer::canonical::{Canonical, CanonicalQueryResponse};
|
||||
use crate::traits::ObligationCtxt;
|
||||
|
||||
@@ -5,6 +5,7 @@ use rustc_infer::infer::region_constraints::RegionConstraintData;
|
||||
use rustc_middle::traits::query::NoSolution;
|
||||
use rustc_middle::ty::{TyCtxt, TypeFoldable};
|
||||
use rustc_span::Span;
|
||||
use tracing::info;
|
||||
|
||||
use crate::infer::canonical::query_response;
|
||||
use crate::infer::InferCtxt;
|
||||
|
||||
@@ -9,6 +9,7 @@ use rustc_span::def_id::CRATE_DEF_ID;
|
||||
use rustc_span::DUMMY_SP;
|
||||
use rustc_type_ir::outlives::{push_outlives_components, Component};
|
||||
use smallvec::{smallvec, SmallVec};
|
||||
use tracing::debug;
|
||||
|
||||
use crate::traits::query::NoSolution;
|
||||
use crate::traits::{wf, ObligationCtxt};
|
||||
|
||||
@@ -16,6 +16,7 @@ use rustc_infer::traits::{Obligation, ObligationCause, PolyTraitObligation, Sele
|
||||
use rustc_middle::ty::fast_reject::{DeepRejectCtxt, TreatParams};
|
||||
use rustc_middle::ty::{self, ToPolyTraitRef, Ty, TypeVisitableExt};
|
||||
use rustc_middle::{bug, span_bug};
|
||||
use tracing::{debug, instrument, trace};
|
||||
|
||||
use super::SelectionCandidate::*;
|
||||
use super::{BuiltinImplConditions, SelectionCandidateSet, SelectionContext, TraitObligationStack};
|
||||
|
||||
@@ -21,6 +21,7 @@ use rustc_middle::ty::{
|
||||
};
|
||||
use rustc_middle::{bug, span_bug};
|
||||
use rustc_span::def_id::DefId;
|
||||
use tracing::{debug, instrument};
|
||||
|
||||
use super::SelectionCandidate::{self, *};
|
||||
use super::{BuiltinImplConditions, SelectionContext};
|
||||
|
||||
@@ -31,6 +31,7 @@ use rustc_middle::ty::{
|
||||
};
|
||||
use rustc_span::symbol::sym;
|
||||
use rustc_span::Symbol;
|
||||
use tracing::{debug, instrument, trace};
|
||||
|
||||
use self::EvaluationResult::*;
|
||||
use self::SelectionCandidate::*;
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
//! [rustc dev guide]: https://rustc-dev-guide.rust-lang.org/traits/specialization.html
|
||||
|
||||
pub mod specialization_graph;
|
||||
|
||||
use rustc_data_structures::fx::FxIndexSet;
|
||||
use rustc_errors::codes::*;
|
||||
use rustc_errors::{Diag, EmissionGuarantee};
|
||||
@@ -22,6 +23,7 @@ use rustc_middle::ty::{self, GenericArgsRef, ImplSubject, Ty, TyCtxt, TypeVisita
|
||||
use rustc_session::lint::builtin::{COHERENCE_LEAK_CHECK, ORDER_DEPENDENT_TRAIT_OBJECTS};
|
||||
use rustc_span::{sym, ErrorGuaranteed, Span, DUMMY_SP};
|
||||
use specialization_graph::GraphExt;
|
||||
use tracing::{debug, instrument};
|
||||
|
||||
use super::{util, SelectionContext};
|
||||
use crate::error_reporting::traits::to_pretty_impl_header;
|
||||
|
||||
@@ -5,6 +5,7 @@ use rustc_middle::bug;
|
||||
pub use rustc_middle::traits::specialization_graph::*;
|
||||
use rustc_middle::ty::fast_reject::{self, SimplifiedType, TreatParams};
|
||||
use rustc_middle::ty::{self, TyCtxt, TypeVisitableExt};
|
||||
use tracing::{debug, instrument};
|
||||
|
||||
use super::OverlapError;
|
||||
use crate::traits;
|
||||
|
||||
@@ -12,6 +12,7 @@ use rustc_middle::ty::{
|
||||
};
|
||||
use rustc_span::Span;
|
||||
use smallvec::{smallvec, SmallVec};
|
||||
use tracing::debug;
|
||||
|
||||
use super::{NormalizeExt, ObligationCause, PredicateObligation, SelectionContext};
|
||||
|
||||
|
||||
@@ -10,6 +10,7 @@ use rustc_middle::ty::{
|
||||
};
|
||||
use rustc_span::{sym, Span, DUMMY_SP};
|
||||
use smallvec::{smallvec, SmallVec};
|
||||
use tracing::debug;
|
||||
|
||||
use crate::errors::DumpVTableEntries;
|
||||
use crate::traits::{impossible_predicates, is_vtable_safe_method};
|
||||
|
||||
@@ -10,6 +10,7 @@ use rustc_middle::ty::{
|
||||
};
|
||||
use rustc_span::def_id::{DefId, LocalDefId, CRATE_DEF_ID};
|
||||
use rustc_span::{Span, DUMMY_SP};
|
||||
use tracing::{debug, instrument, trace};
|
||||
|
||||
use crate::infer::InferCtxt;
|
||||
use crate::traits;
|
||||
|
||||
Reference in New Issue
Block a user