Mercurial > public > mercurial-scm > hg
view rust/hg-core/src/transaction.rs @ 52970:e4ff37b5317c
stream-bundle: simple use of `mode` argument of `os.open`
This argument have been around for a while and simplify the code. This is
especially true as Windows does not have `os.fchmod` so we would have had to
deal with this special case.
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Tue, 18 Feb 2025 17:21:42 +0100 |
parents | e01e84e5e426 |
children |
line wrap: on
line source
use std::path::Path; /// The Mercurial transaction system is based on the append-only nature /// of its core files. This exposes the necessary methods to safely write to /// the different core datastructures. pub trait Transaction { /// Record the state of an append-only file before update fn add(&mut self, file: impl AsRef<Path>, offset: usize); // TODO the rest of the methods once we do more in Rust. }