1
Fork 0

Remove extern crate rustc_macros from numerous crates.

This commit is contained in:
Nicholas Nethercote 2024-04-29 08:53:45 +10:00
parent 10505a1cc9
commit 4814fd0a4b
110 changed files with 99 additions and 94 deletions

View file

@ -15,6 +15,7 @@ use rustc_data_structures::stable_hasher::{StableOrd, ToStableHashKey};
use rustc_errors::emitter::HumanReadableErrorType;
use rustc_errors::{ColorConfig, DiagArgValue, DiagCtxtFlags, IntoDiagArg};
use rustc_feature::UnstableFeatures;
use rustc_macros::{Decodable, Encodable, HashStable_Generic};
use rustc_span::edition::{Edition, DEFAULT_EDITION, EDITION_NAME_LIST, LATEST_STABLE_EDITION};
use rustc_span::source_map::FilePathMapping;
use rustc_span::{FileName, FileNameDisplayPreference, RealFileName, SourceFileHashAlgorithm};

View file

@ -10,6 +10,7 @@ use rustc_hir::def_id::{
CrateNum, DefId, LocalDefId, StableCrateId, StableCrateIdMap, LOCAL_CRATE,
};
use rustc_hir::definitions::{DefKey, DefPath, DefPathHash, Definitions};
use rustc_macros::{Decodable, Encodable, HashStable_Generic};
use rustc_span::symbol::Symbol;
use rustc_span::Span;
use rustc_target::spec::abi::Abi;

View file

@ -6,7 +6,7 @@ use rustc_errors::{
codes::*, Diag, DiagCtxt, DiagMessage, Diagnostic, EmissionGuarantee, ErrorGuaranteed, Level,
MultiSpan,
};
use rustc_macros::Diagnostic;
use rustc_macros::{Diagnostic, Subdiagnostic};
use rustc_span::{Span, Symbol};
use rustc_target::spec::{SplitDebuginfo, StackProtector, TargetTriple};

View file

@ -6,8 +6,6 @@
#![feature(iter_intersperse)]
#![allow(internal_features)]
#[macro_use]
extern crate rustc_macros;
pub mod errors;
#[macro_use]

View file

@ -1,5 +1,6 @@
use crate::filesearch::make_target_lib_path;
use crate::EarlyDiagCtxt;
use rustc_macros::{Decodable, Encodable, HashStable_Generic};
use rustc_target::spec::TargetTriple;
use std::path::{Path, PathBuf};

View file

@ -1,6 +1,7 @@
use crate::session::Session;
use rustc_data_structures::profiling::VerboseTimingGuard;
use rustc_fs_util::try_canonicalize;
use rustc_macros::{Decodable, Encodable, HashStable_Generic};
use std::{
path::{Path, PathBuf},
sync::OnceLock,

View file

@ -1,3 +1,4 @@
use rustc_macros::{current_rustc_version, Decodable, Encodable, HashStable_Generic};
use std::fmt::{self, Display};
#[derive(Encodable, Decodable, Copy, Clone, Debug, PartialEq, Eq, PartialOrd, Ord, Hash)]