File tree 2 files changed +5
-5
lines changed
2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ pub fn render() -> Result<Vec<Tokens>> {
20
20
generic_items. push ( quote ! {
21
21
///Value read from the register
22
22
pub struct FR <U , T > {
23
- bits: U ,
23
+ pub ( crate ) bits: U ,
24
24
_reg: marker:: PhantomData <T >,
25
25
}
26
26
Original file line number Diff line number Diff line change @@ -337,11 +337,11 @@ pub fn fields(
337
337
let value = if offset != 0 {
338
338
let offset = & f. offset ;
339
339
quote ! {
340
- ( ( self . bits( ) >> #offset) & #mask) #cast
340
+ ( ( self . bits >> #offset) & #mask) #cast
341
341
}
342
342
} else {
343
343
quote ! {
344
- ( self . bits( ) & #mask) #cast
344
+ ( self . bits & #mask) #cast
345
345
}
346
346
} ;
347
347
@@ -407,7 +407,7 @@ pub fn fields(
407
407
#[ inline( always) ]
408
408
pub fn variant( & self ) -> crate :: Variant <#fty, #pc_r> {
409
409
use crate :: Variant :: * ;
410
- match self . bits( ) {
410
+ match self . bits {
411
411
#( #arms) , *
412
412
}
413
413
}
@@ -417,7 +417,7 @@ pub fn fields(
417
417
///Enumerated values
418
418
#[ inline( always) ]
419
419
pub fn variant( & self ) -> #pc_r {
420
- match self . bits( ) {
420
+ match self . bits {
421
421
#( #arms) , *
422
422
}
423
423
}
You can’t perform that action at this time.
0 commit comments