diff options
Diffstat (limited to 'ext/fs/lib.rs')
-rw-r--r-- | ext/fs/lib.rs | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/ext/fs/lib.rs b/ext/fs/lib.rs index 4fdf6b3f1..fb0a6ffed 100644 --- a/ext/fs/lib.rs +++ b/ext/fs/lib.rs @@ -3,14 +3,18 @@ mod interface; mod ops; mod std_fs; +pub mod sync; pub use crate::interface::FileSystem; +pub use crate::interface::FileSystemRc; pub use crate::interface::FsDirEntry; pub use crate::interface::FsFileType; pub use crate::interface::OpenOptions; -use crate::ops::*; - pub use crate::std_fs::RealFs; +pub use crate::sync::MaybeSend; +pub use crate::sync::MaybeSync; + +use crate::ops::*; use deno_core::error::AnyError; use deno_core::OpState; @@ -18,7 +22,6 @@ use std::cell::RefCell; use std::convert::From; use std::path::Path; use std::rc::Rc; -use std::sync::Arc; pub trait FsPermissions { fn check_read(&mut self, p: &Path, api_name: &str) -> Result<(), AnyError>; @@ -153,7 +156,7 @@ deno_core::extension!(deno_fs, esm = [ "30_fs.js" ], options = { unstable: bool, - fs: Arc<dyn FileSystem>, + fs: FileSystemRc, }, state = |state, options| { state.put(UnstableChecker { unstable: options.unstable }); |