File tree 2 files changed +6
-2
lines changed
compiler/rustc_hir_analysis/src/astconv
2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -2630,7 +2630,7 @@ impl<'o, 'tcx> dyn AstConv<'tcx> + 'o {
2630
2630
assert_eq ! ( opt_self_ty, None ) ;
2631
2631
self . prohibit_generics ( path. segments . split_last ( ) . unwrap ( ) . 1 . iter ( ) , |_| { } ) ;
2632
2632
2633
- if let Some ( identity_def_id) = tcx. lang_items ( ) . identity_type ( ) {
2633
+ if let Some ( identity_def_id) = tcx. lang_items ( ) . identity_type ( ) && std :: env :: var ( "TEST_WITH_IDENTITY" ) . is_ok ( ) {
2634
2634
let item_segment = path. segments . split_last ( ) . unwrap ( ) ;
2635
2635
2636
2636
let substs = self . ast_path_substs_for_ty ( span, def_id, item_segment. 0 ) ;
Original file line number Diff line number Diff line change @@ -786,11 +786,15 @@ unsafe impl<T: ?Sized> Freeze for &mut T {}
786
786
/// // becomes:
787
787
/// type Foo = <Bar as Identity>::Identity;
788
788
/// ```
789
- pub ( crate ) trait Identity : Sized {
789
+ #[ stable( feature = "pin" , since = "1.33.0" ) ]
790
+ pub trait Identity : Sized {
790
791
#[ cfg_attr( not( bootstrap) , lang = "identity" ) ]
792
+ #[ stable( feature = "pin" , since = "1.33.0" ) ]
793
+ /// lol
791
794
type Identity ;
792
795
}
793
796
797
+ #[ stable( feature = "pin" , since = "1.33.0" ) ]
794
798
impl < T > Identity for T {
795
799
type Identity = T ;
796
800
}
You can’t perform that action at this time.
0 commit comments