@@ -114,14 +114,11 @@ fn write_path(out: &mut String, path: &Vec<PathElem>) {
114114 ClosureVar ( name) => write ! ( out, ".<closure-var({})>" , name) ,
115115 TupleElem ( idx) => write ! ( out, ".{}" , idx) ,
116116 ArrayElem ( idx) => write ! ( out, "[{}]" , idx) ,
117- Deref =>
118- // This does not match Rust syntax, but it is more readable for long paths -- and
117+ // `.<deref>` does not match Rust syntax, but it is more readable for long paths -- and
119118 // some of the other items here also are not Rust syntax. Actually we can't
120119 // even use the usual syntax because we are just showing the projections,
121120 // not the root.
122- {
123- write ! ( out, ".<deref>" )
124- }
121+ Deref => write ! ( out, ".<deref>" ) ,
125122 Tag => write ! ( out, ".<enum-tag>" ) ,
126123 DynDowncast => write ! ( out, ".<dyn-downcast>" ) ,
127124 }
@@ -206,9 +203,8 @@ impl<'rt, 'mir, 'tcx, M: Machine<'mir, 'tcx>> ValidityVisitor<'rt, 'mir, 'tcx, M
206203 ty:: Adt ( def, ..) if def. is_enum ( ) => {
207204 // we might be projecting *to* a variant, or to a field *in*a variant.
208205 match layout. variants {
209- layout:: Variants :: Single { index } =>
210- // Inside a variant
211- {
206+ layout:: Variants :: Single { index } => {
207+ // Inside a variant
212208 PathElem :: Field ( def. variants [ index] . fields [ field] . ident . name )
213209 }
214210 _ => bug ! ( ) ,
0 commit comments