Skip to content

Commit 814e3af

Browse files
authored
Rollup merge of #67786 - Centril:canon-span, r=petrochenkov
Nix reexports from `rustc_span` in `syntax` Remove reexports `syntax::{source_map, symbol, edition}` and use `rustc_span` paths directly. r? @petrochenkov
2 parents 93ff897 + 6e4ea14 commit 814e3af

File tree

235 files changed

+352
-356
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

235 files changed

+352
-356
lines changed

src/librustc/arena.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ macro_rules! arena_types {
9494
>
9595
>,
9696
[few] diagnostic_items: rustc_data_structures::fx::FxHashMap<
97-
syntax::symbol::Symbol,
97+
rustc_span::symbol::Symbol,
9898
rustc::hir::def_id::DefId,
9999
>,
100100
[few] resolve_lifetimes: rustc::middle::resolve_lifetime::ResolveLifetimes,
@@ -105,7 +105,7 @@ macro_rules! arena_types {
105105
[few] privacy_access_levels: rustc::middle::privacy::AccessLevels,
106106
[few] target_features_whitelist: rustc_data_structures::fx::FxHashMap<
107107
String,
108-
Option<syntax::symbol::Symbol>
108+
Option<rustc_span::symbol::Symbol>
109109
>,
110110
[few] wasm_import_module_map: rustc_data_structures::fx::FxHashMap<
111111
rustc::hir::def_id::DefId,

src/librustc/hir/check_attr.rs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,12 @@ use crate::lint::builtin::UNUSED_ATTRIBUTES;
1212
use crate::ty::query::Providers;
1313
use crate::ty::TyCtxt;
1414

15+
use rustc_error_codes::*;
16+
use rustc_span::symbol::sym;
1517
use rustc_span::Span;
16-
use std::fmt::{self, Display};
17-
use syntax::{attr, symbol::sym};
18+
use syntax::attr;
1819

19-
use rustc_error_codes::*;
20+
use std::fmt::{self, Display};
2021

2122
#[derive(Copy, Clone, PartialEq)]
2223
pub(crate) enum MethodKind {

src/librustc/hir/map/collector.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ use crate::session::Session;
1111
use crate::util::nodemap::FxHashMap;
1212
use rustc_data_structures::svh::Svh;
1313
use rustc_index::vec::IndexVec;
14+
use rustc_span::source_map::SourceMap;
1415
use rustc_span::Span;
1516
use std::iter::repeat;
1617
use syntax::ast::NodeId;
17-
use syntax::source_map::SourceMap;
1818

1919
use crate::ich::StableHashingContext;
2020
use rustc_data_structures::stable_hasher::{HashStable, StableHasher};

src/librustc/hir/map/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,10 @@ use crate::util::nodemap::FxHashMap;
1717
use rustc_data_structures::svh::Svh;
1818
use rustc_index::vec::IndexVec;
1919
use rustc_span::hygiene::MacroKind;
20+
use rustc_span::source_map::Spanned;
2021
use rustc_span::{Span, DUMMY_SP};
2122
use rustc_target::spec::abi::Abi;
2223
use syntax::ast::{self, Name, NodeId};
23-
use syntax::source_map::Spanned;
2424

2525
pub mod blocks;
2626
mod collector;

src/librustc/hir/print.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1+
use rustc_span::source_map::{SourceMap, Spanned};
2+
use rustc_span::symbol::kw;
13
use rustc_span::{self, BytePos, FileName};
24
use rustc_target::spec::abi::Abi;
35
use syntax::ast;
46
use syntax::print::pp::Breaks::{Consistent, Inconsistent};
57
use syntax::print::pp::{self, Breaks};
68
use syntax::print::pprust::{self, Comments, PrintState};
79
use syntax::sess::ParseSess;
8-
use syntax::source_map::{SourceMap, Spanned};
9-
use syntax::symbol::kw;
1010
use syntax::util::parser::{self, AssocOp, Fixity};
1111

1212
use crate::hir;

src/librustc/ich/hcx.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,10 @@ use crate::ty::{fast_reject, TyCtxt};
99

1010
use std::cmp::Ord;
1111

12+
use rustc_span::source_map::SourceMap;
13+
use rustc_span::symbol::Symbol;
1214
use rustc_span::{BytePos, SourceFile};
1315
use syntax::ast;
14-
use syntax::source_map::SourceMap;
15-
use syntax::symbol::Symbol;
1616

1717
use rustc_data_structures::fx::{FxHashMap, FxHashSet};
1818
use rustc_data_structures::stable_hasher::{HashStable, StableHasher, ToStableHashKey};

src/librustc/ich/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ pub use self::hcx::{
44
hash_stable_trait_impls, NodeIdHashingMode, StableHashingContext, StableHashingContextProvider,
55
};
66
crate use rustc_data_structures::fingerprint::Fingerprint;
7+
use rustc_span::symbol::{sym, Symbol};
78
pub use rustc_span::CachingSourceMapView;
8-
use syntax::symbol::{sym, Symbol};
99

1010
mod hcx;
1111

src/librustc/infer/canonical/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@ use crate::ty::{self, BoundVar, List, Region, TyCtxt};
3030
use rustc_index::vec::IndexVec;
3131
use rustc_macros::HashStable;
3232
use rustc_serialize::UseSpecializedDecodable;
33+
use rustc_span::source_map::Span;
3334
use smallvec::SmallVec;
3435
use std::ops::Index;
35-
use syntax::source_map::Span;
3636

3737
mod canonicalizer;
3838

src/librustc/infer/error_reporting/need_type_info.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@ use crate::infer::InferCtxt;
66
use crate::ty::print::Print;
77
use crate::ty::{self, DefIdTree, Infer, Ty, TyVar};
88
use errors::{Applicability, DiagnosticBuilder};
9+
use rustc_span::source_map::DesugaringKind;
10+
use rustc_span::symbol::kw;
911
use rustc_span::Span;
1012
use std::borrow::Cow;
11-
use syntax::source_map::DesugaringKind;
12-
use syntax::symbol::kw;
1313

1414
use rustc_error_codes::*;
1515

src/librustc/infer/error_reporting/nice_region_error/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ use crate::infer::InferCtxt;
44
use crate::ty::{self, TyCtxt};
55
use crate::util::common::ErrorReported;
66
use errors::DiagnosticBuilder;
7-
use syntax::source_map::Span;
7+
use rustc_span::source_map::Span;
88

99
mod different_lifetimes;
1010
mod find_anon_type;

0 commit comments

Comments
 (0)