@@ -70,7 +70,7 @@ fn main() {
70
70
test_abi_compat ( 0usize , 0u64 ) ;
71
71
test_abi_compat ( 0isize , 0i64 ) ;
72
72
}
73
- test_abi_compat ( 42u32 , num:: NonZeroU32 :: new ( 1 ) . unwrap ( ) ) ;
73
+ test_abi_compat ( 42u32 , num:: NonZero :: new ( 1u32 ) . unwrap ( ) ) ;
74
74
// - `char` and `u32`.
75
75
test_abi_compat ( 42u32 , 'x' ) ;
76
76
// - Reference/pointer types with the same pointee.
@@ -86,9 +86,9 @@ fn main() {
86
86
// - Guaranteed null-pointer-optimizations (RFC 3391).
87
87
test_abi_compat ( & 0u32 as * const u32 , Some ( & 0u32 ) ) ;
88
88
test_abi_compat ( main as fn ( ) , Some ( main as fn ( ) ) ) ;
89
- test_abi_compat ( 0u32 , Some ( num:: NonZeroU32 :: new ( 1 ) . unwrap ( ) ) ) ;
89
+ test_abi_compat ( 0u32 , Some ( num:: NonZero :: new ( 1u32 ) . unwrap ( ) ) ) ;
90
90
test_abi_compat ( & 0u32 as * const u32 , Some ( Wrapper ( & 0u32 ) ) ) ;
91
- test_abi_compat ( 0u32 , Some ( Wrapper ( num:: NonZeroU32 :: new ( 1 ) . unwrap ( ) ) ) ) ;
91
+ test_abi_compat ( 0u32 , Some ( Wrapper ( num:: NonZero :: new ( 1u32 ) . unwrap ( ) ) ) ) ;
92
92
93
93
// These must work for *any* type, since we guarantee that `repr(transparent)` is ABI-compatible
94
94
// with the wrapped field.
@@ -102,7 +102,7 @@ fn main() {
102
102
test_abi_newtype :: < [ u32 ; 2 ] > ( ) ;
103
103
test_abi_newtype :: < [ u32 ; 32 ] > ( ) ;
104
104
test_abi_newtype :: < Option < i32 > > ( ) ;
105
- test_abi_newtype :: < Option < num:: NonZeroU32 > > ( ) ;
105
+ test_abi_newtype :: < Option < num:: NonZero < u32 > > > ( ) ;
106
106
107
107
// Extra test for assumptions made by arbitrary-self-dyn-receivers.
108
108
// This is interesting since these types are not `repr(transparent)`. So this is not part of our
0 commit comments