pub enum WriteLimit {
Full,
Create,
}Expand description
What a run may do to a file that already exists inside its write
domain (crates/kernel/spec/WriteDomain.lean §8-78).
It narrows the domain and never widens it: the domain answers where
a run may write and what kind of file, this answers whether a write
may change a file that is already there. Whether the target exists
is the filesystem’s fact at the moment of the write, so the check
that makes Create hold is the writer’s atomic create; the rule and
its refusal are crate::gate::replacing.
Variants§
Full
No narrowing beyond the write domain.
Create
Create files that do not exist; change, remove and rename none, including one this run created itself.
Implementations§
Source§impl WriteLimit
impl WriteLimit
Trait Implementations§
Source§impl Clone for WriteLimit
impl Clone for WriteLimit
impl Copy for WriteLimit
Source§impl Debug for WriteLimit
impl Debug for WriteLimit
Source§impl<'de> Deserialize<'de> for WriteLimit
impl<'de> Deserialize<'de> for WriteLimit
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for WriteLimit
Source§impl Ord for WriteLimit
impl Ord for WriteLimit
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialEq for WriteLimit
impl PartialEq for WriteLimit
Source§impl PartialOrd for WriteLimit
impl PartialOrd for WriteLimit
Source§impl Serialize for WriteLimit
impl Serialize for WriteLimit
impl StructuralPartialEq for WriteLimit
Auto Trait Implementations§
impl Freeze for WriteLimit
impl RefUnwindSafe for WriteLimit
impl Send for WriteLimit
impl Sync for WriteLimit
impl Unpin for WriteLimit
impl UnsafeUnpin for WriteLimit
impl UnwindSafe for WriteLimit
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more