File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -160,6 +160,10 @@ impl OpenOptionsExt for OpenOptions {
160160// casts and rely on manual lowering to `stat` if the raw type is desired.
161161#[ stable( feature = "metadata_ext" , since = "1.1.0" ) ]
162162pub trait MetadataExt {
163+ #[ stable( feature = "metadata_ext" , since = "1.1.0" ) ]
164+ fn dev ( & self ) -> u64 ;
165+ #[ stable( feature = "metadata_ext" , since = "1.1.0" ) ]
166+ fn ino ( & self ) -> u64 ;
163167 #[ stable( feature = "metadata_ext" , since = "1.1.0" ) ]
164168 fn mode ( & self ) -> u32 ;
165169 #[ stable( feature = "metadata_ext" , since = "1.1.0" ) ]
@@ -184,6 +188,12 @@ pub trait MetadataExt {
184188
185189#[ stable( feature = "metadata_ext" , since = "1.1.0" ) ]
186190impl MetadataExt for fs:: Metadata {
191+ fn dev ( & self ) -> u64 {
192+ self . as_inner ( ) . as_inner ( ) . st_dev as u64
193+ }
194+ fn ino ( & self ) -> u64 {
195+ self . as_inner ( ) . as_inner ( ) . st_ino as u64
196+ }
187197 fn mode ( & self ) -> u32 {
188198 self . as_inner ( ) . as_inner ( ) . st_mode as u32
189199 }
You can’t perform that action at this time.
0 commit comments