File tree Expand file tree Collapse file tree 1 file changed +5
-9
lines changed
Expand file tree Collapse file tree 1 file changed +5
-9
lines changed Original file line number Diff line number Diff line change @@ -394,19 +394,16 @@ impl RamFile {
394394 }
395395}
396396
397+ type MemDirectoryMap = BTreeMap < String , Box < dyn VfsNode + core:: marker:: Send + core:: marker:: Sync > > ;
398+
397399pub struct MemDirectoryInterface {
398400 /// Directory entries
399- inner :
400- Arc < RwLock < BTreeMap < String , Box < dyn VfsNode + core:: marker:: Send + core:: marker:: Sync > > > > ,
401+ inner : Arc < RwLock < MemDirectoryMap > > ,
401402 read_idx : Mutex < usize > ,
402403}
403404
404405impl MemDirectoryInterface {
405- pub fn new (
406- inner : Arc <
407- RwLock < BTreeMap < String , Box < dyn VfsNode + core:: marker:: Send + core:: marker:: Sync > > > ,
408- > ,
409- ) -> Self {
406+ pub fn new ( inner : Arc < RwLock < MemDirectoryMap > > ) -> Self {
410407 Self {
411408 inner,
412409 read_idx : Mutex :: new ( 0 ) ,
@@ -477,8 +474,7 @@ impl ObjectInterface for MemDirectoryInterface {
477474
478475#[ derive( Debug ) ]
479476pub ( crate ) struct MemDirectory {
480- inner :
481- Arc < RwLock < BTreeMap < String , Box < dyn VfsNode + core:: marker:: Send + core:: marker:: Sync > > > > ,
477+ inner : Arc < RwLock < MemDirectoryMap > > ,
482478 attr : FileAttr ,
483479}
484480
You can’t perform that action at this time.
0 commit comments