pub struct SectionId(/* private fields */);
Expand description
The section ID is a monotonically increasing ID used to refer to section bodies.
This value does not imply any ordering between sections, as new sections
with higher section IDs may be in between lower ID sections after File
mutation.
We need to use a section id because git-config
permits sections with
identical names, making it ambiguous when used in maps, for instance.
This id guaranteed to be unique, but not guaranteed to be compact. In other words, it’s possible that a section may have an ID of 3 but the next section has an ID of 5 as 4 was deleted.
Trait Implementations§
source§impl Ord for SectionId
impl Ord for SectionId
source§impl PartialOrd for SectionId
impl PartialOrd for SectionId
impl Copy for SectionId
impl Eq for SectionId
impl StructuralPartialEq for SectionId
Auto Trait Implementations§
impl Freeze for SectionId
impl RefUnwindSafe for SectionId
impl Send for SectionId
impl Sync for SectionId
impl Unpin for SectionId
impl UnwindSafe for SectionId
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)