File tree Expand file tree Collapse file tree 7 files changed +7
-7
lines changed Expand file tree Collapse file tree 7 files changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -346,7 +346,7 @@ impl<'hir> Map<'hir> {
346346 }
347347
348348 fn get_entry ( & self , id : HirId ) -> Entry < ' hir > {
349- if id. local_id == ItemLocalId :: from_u32_const ( 0 ) {
349+ if id. local_id == ItemLocalId :: from_u32 ( 0 ) {
350350 let owner = self . tcx . hir_owner ( id. owner_def_id ( ) ) ;
351351 Entry { parent : owner. parent , node : owner. node }
352352 } else {
Original file line number Diff line number Diff line change @@ -1697,7 +1697,7 @@ rustc_index::newtype_index! {
16971697}
16981698
16991699impl UniverseIndex {
1700- pub const ROOT : UniverseIndex = UniverseIndex :: from_u32_const ( 0 ) ;
1700+ pub const ROOT : UniverseIndex = UniverseIndex :: from_u32 ( 0 ) ;
17011701
17021702 /// Returns the "next" universe index in order -- this new index
17031703 /// is considered to extend all previous universes. This
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ rustc_index::newtype_index! {
1212rustc_data_structures:: define_id_collections!( NodeMap , NodeSet , NodeId ) ;
1313
1414/// `NodeId` used to represent the root of the crate.
15- pub const CRATE_NODE_ID : NodeId = NodeId :: from_u32_const ( 0 ) ;
15+ pub const CRATE_NODE_ID : NodeId = NodeId :: from_u32 ( 0 ) ;
1616
1717/// When parsing and doing expansions, we initially give all AST nodes this AST
1818/// node value. Then later, in the renumber pass, we renumber them to have
Original file line number Diff line number Diff line change @@ -71,7 +71,7 @@ rustc_data_structures::impl_stable_hash_via_hash!(ItemLocalId);
7171
7272/// The `HirId` corresponding to `CRATE_NODE_ID` and `CRATE_DEF_INDEX`.
7373pub const CRATE_HIR_ID : HirId =
74- HirId { owner : CRATE_DEF_INDEX , local_id : ItemLocalId :: from_u32_const ( 0 ) } ;
74+ HirId { owner : CRATE_DEF_INDEX , local_id : ItemLocalId :: from_u32 ( 0 ) } ;
7575
7676pub const DUMMY_HIR_ID : HirId = HirId { owner : CRATE_DEF_INDEX , local_id : DUMMY_ITEM_LOCAL_ID } ;
7777
Original file line number Diff line number Diff line change @@ -482,7 +482,7 @@ macro_rules! newtype_index {
482482 const $name: ident = $constant: expr,
483483 $( $tokens: tt) * ) => (
484484 $( #[ doc = $doc] ) *
485- $v const $name: $type = $type:: from_u32_const ( $constant) ;
485+ $v const $name: $type = $type:: from_u32 ( $constant) ;
486486 $crate:: newtype_index!(
487487 @derives [ $( $derives, ) * ]
488488 @attrs [ $( #[ $attrs] ) * ]
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ pub enum CrateNum {
2525
2626/// Item definitions in the currently-compiled crate would have the `CrateNum`
2727/// `LOCAL_CRATE` in their `DefId`.
28- pub const LOCAL_CRATE : CrateNum = CrateNum :: Index ( CrateId :: from_u32_const ( 0 ) ) ;
28+ pub const LOCAL_CRATE : CrateNum = CrateNum :: Index ( CrateId :: from_u32 ( 0 ) ) ;
2929
3030impl Idx for CrateNum {
3131 #[ inline]
Original file line number Diff line number Diff line change @@ -997,7 +997,7 @@ rustc_index::newtype_index! {
997997
998998impl Symbol {
999999 const fn new ( n : u32 ) -> Self {
1000- Symbol ( SymbolIndex :: from_u32_const ( n) )
1000+ Symbol ( SymbolIndex :: from_u32 ( n) )
10011001 }
10021002
10031003 /// Maps a string to its interned representation.
You can’t perform that action at this time.
0 commit comments