File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -121,25 +121,25 @@ pub trait Map<'hir> {
121121// Used when no map is actually available, forcing manual implementation of nested visitors.
122122impl < ' hir > Map < ' hir > for ! {
123123 fn hir_node ( & self , _: HirId ) -> Node < ' hir > {
124- * self ;
124+ unreachable ! ( ) ;
125125 }
126126 fn hir_node_by_def_id ( & self , _: LocalDefId ) -> Node < ' hir > {
127127 * self ;
128128 }
129129 fn body ( & self , _: BodyId ) -> & ' hir Body < ' hir > {
130- * self ;
130+ unreachable ! ( ) ;
131131 }
132132 fn item ( & self , _: ItemId ) -> & ' hir Item < ' hir > {
133- * self ;
133+ unreachable ! ( ) ;
134134 }
135135 fn trait_item ( & self , _: TraitItemId ) -> & ' hir TraitItem < ' hir > {
136- * self ;
136+ unreachable ! ( ) ;
137137 }
138138 fn impl_item ( & self , _: ImplItemId ) -> & ' hir ImplItem < ' hir > {
139- * self ;
139+ unreachable ! ( ) ;
140140 }
141141 fn foreign_item ( & self , _: ForeignItemId ) -> & ' hir ForeignItem < ' hir > {
142- * self ;
142+ unreachable ! ( ) ;
143143 }
144144}
145145
@@ -203,7 +203,7 @@ use nested_filter::NestedFilter;
203203/// to monitor future changes to `Visitor` in case a new method with a
204204/// new default implementation gets introduced.)
205205pub trait Visitor < ' v > : Sized {
206- // this type should not be overridden, it exists for convenient usage as `Self::Map`
206+ // This type should not be overridden, it exists for convenient usage as `Self::Map`.
207207 type Map : Map < ' v > = <Self :: NestedFilter as NestedFilter < ' v > >:: Map ;
208208
209209 ///////////////////////////////////////////////////////////////////////////
You can’t perform that action at this time.
0 commit comments