File tree Expand file tree Collapse file tree 3 files changed +6
-15
lines changed
Expand file tree Collapse file tree 3 files changed +6
-15
lines changed Original file line number Diff line number Diff line change 77// except according to those terms.
88
99use super :: Layout ;
10- use super :: LayoutPriv ;
1110
1211const LAYOUT_NAMES : & [ & str ] = & [ "C" , "F" ] ;
1312
Original file line number Diff line number Diff line change 11mod layoutfmt;
22
3- // public but users don't interact with it
3+ // public struct but users don't interact with it
44#[ doc( hidden) ]
55/// Memory layout description
66#[ derive( Copy , Clone ) ]
77pub struct Layout ( u32 ) ;
88
9- pub trait LayoutPriv : Sized {
10- fn new ( x : u32 ) -> Self ;
11- fn and ( self , flag : Self ) -> Self ;
12- fn is ( self , flag : u32 ) -> bool ;
13- fn flag ( self ) -> u32 ;
14- }
15-
16- impl LayoutPriv for Layout {
9+ impl Layout {
1710 #[ inline( always) ]
18- fn new ( x : u32 ) -> Self {
11+ pub ( crate ) fn new ( x : u32 ) -> Self {
1912 Layout ( x)
2013 }
2114
2215 #[ inline( always) ]
23- fn is ( self , flag : u32 ) -> bool {
16+ pub ( crate ) fn is ( self , flag : u32 ) -> bool {
2417 self . 0 & flag != 0
2518 }
2619 #[ inline( always) ]
27- fn and ( self , flag : Layout ) -> Layout {
20+ pub ( crate ) fn and ( self , flag : Layout ) -> Layout {
2821 Layout ( self . 0 & flag. 0 )
2922 }
3023
3124 #[ inline( always) ]
32- fn flag ( self ) -> u32 {
25+ pub ( crate ) fn flag ( self ) -> u32 {
3326 self . 0
3427 }
3528}
Original file line number Diff line number Diff line change @@ -18,7 +18,6 @@ use crate::Layout;
1818use crate :: NdIndex ;
1919
2020use crate :: indexes:: { indices, Indices } ;
21- use crate :: layout:: LayoutPriv ;
2221use crate :: layout:: { CORDER , FORDER } ;
2322
2423/// Return if the expression is a break value.
You can’t perform that action at this time.
0 commit comments