@@ -193,22 +193,24 @@ fn main() {
193
193
assert_eq!(r.saturating_pow(3), -8 as i128);
194
194
assert_eq!(r.saturating_pow(0), 1 as i128);*/
195
195
196
- const A : u64 = 0b0101100 ;
197
- const B : u64 = 0b0100001 ;
198
- const C : u64 = 0b1111001 ;
196
+ {
197
+ const A : u128 = 0b0101100 ;
198
+ const B : u128 = 0b0100001 ;
199
+ const C : u128 = 0b1111001 ;
199
200
200
- const _0: u64 = 0 ;
201
- const _1: u64 = !0 ;
201
+ const _0: u128 = 0 ;
202
+ const _1: u128 = !0 ;
202
203
203
- assert_eq ! ( A . reverse_bits( ) . reverse_bits( ) , A ) ;
204
- assert_eq ! ( B . reverse_bits( ) . reverse_bits( ) , B ) ;
205
- assert_eq ! ( C . reverse_bits( ) . reverse_bits( ) , C ) ;
204
+ assert_eq ! ( A . reverse_bits( ) . reverse_bits( ) , A ) ;
205
+ assert_eq ! ( B . reverse_bits( ) . reverse_bits( ) , B ) ;
206
+ assert_eq ! ( C . reverse_bits( ) . reverse_bits( ) , C ) ;
206
207
207
- // Swapping these should make no difference
208
- assert_eq ! ( _0. reverse_bits( ) , _0) ;
209
- assert_eq ! ( _1. reverse_bits( ) , _1) ;
208
+ // Swapping these should make no difference
209
+ assert_eq ! ( _0. reverse_bits( ) , _0) ;
210
+ assert_eq ! ( _1. reverse_bits( ) , _1) ;
211
+ }
210
212
211
- /* const _0: i128 = 0;
213
+ const _0: i128 = 0 ;
212
214
const _1: i128 = !0 ;
213
215
214
216
use std:: i128:: MAX ;
@@ -233,5 +235,5 @@ fn main() {
233
235
234
236
let x: i128 = 0b0010_1100 ;
235
237
assert_eq ! ( x. leading_ones( ) , 0 ) ;
236
- assert_eq!(x.trailing_ones(), 0);*/
238
+ assert_eq ! ( x. trailing_ones( ) , 0 ) ;
237
239
}
0 commit comments