File tree 3 files changed +2
-7
lines changed
3 files changed +2
-7
lines changed Original file line number Diff line number Diff line change @@ -2004,12 +2004,6 @@ extern "rust-intrinsic" {
2004
2004
pub fn ptr_guaranteed_ne < T > ( ptr : * const T , other : * const T ) -> bool ;
2005
2005
}
2006
2006
2007
- #[ rustc_const_unstable( feature = "variant_count" , issue = "73662" ) ]
2008
- #[ cfg( bootstrap) ]
2009
- pub const fn variant_count < T > ( ) -> usize {
2010
- 0
2011
- }
2012
-
2013
2007
// Some functions are defined here because they accidentally got made
2014
2008
// available in this module on stable. See <https://github.com/rust-lang/rust/issues/15702>.
2015
2009
// (`transmute` also falls into this category, but it cannot be wrapped due to the
Original file line number Diff line number Diff line change 125
125
#![ feature( unsized_locals) ]
126
126
#![ feature( untagged_unions) ]
127
127
#![ feature( unwind_attributes) ]
128
- #![ feature( variant_count) ]
128
+ #![ cfg_attr ( not ( bootstrap ) , feature( variant_count) ) ]
129
129
#![ feature( doc_alias) ]
130
130
#![ feature( mmx_target_feature) ]
131
131
#![ feature( tbm_target_feature) ]
Original file line number Diff line number Diff line change @@ -1037,6 +1037,7 @@ pub const fn discriminant<T>(v: &T) -> Discriminant<T> {
1037
1037
/// assert_eq!(mem::variant_count::<Result<!, !>>(), 2);
1038
1038
/// ```
1039
1039
#[ inline( always) ]
1040
+ #[ cfg( not( bootstrap) ) ]
1040
1041
#[ unstable( feature = "variant_count" , issue = "73662" ) ]
1041
1042
#[ rustc_const_unstable( feature = "variant_count" , issue = "73662" ) ]
1042
1043
pub const fn variant_count < T > ( ) -> usize {
You can’t perform that action at this time.
0 commit comments