MCPcopy Create free account
hub / github.com/bendudson/EuraliOS / include_cur_dir

Method include_cur_dir

euralios_std/src/path.rs:753–763  ·  view source on GitHub ↗

Should the normalized path include a leading . ?

(&self)

Source from the content-addressed store, hash-verified

751
752 /// Should the normalized path include a leading . ?
753 fn include_cur_dir(&self) -> bool {
754 if self.has_root() {
755 return false;
756 }
757 let mut iter = self.path[..].iter();
758 match (iter.next(), iter.next()) {
759 (Some(&b'.'), None) => true,
760 (Some(&b'.'), Some(&b)) => self.is_sep_byte(b),
761 _ => false,
762 }
763 }
764
765 // parse a given byte sequence into the corresponding path component
766 fn parse_single_component<'b>(&self, comp: &'b [u8]) -> Option<Component<'b>> {

Callers 3

len_before_bodyMethod · 0.80
nextMethod · 0.80
next_backMethod · 0.80

Calls 4

has_rootMethod · 0.80
iterMethod · 0.80
is_sep_byteMethod · 0.80
nextMethod · 0.45

Tested by

no test coverage detected