1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
//! The base crate under every rusty-backup filesystem, partition and disk-image crate.
//!
//! Always available:
//! - [`io_other`] / [`repeat_n`]: std shims that build on both current Rust and
//! Rust 1.73 (the last toolchain whose std targets macOS 10.7).
//! - [`display`]: small neutral formatters (sizes, Mac `OSType`, Unix modes).
//! - [`bits`]: big-endian allocation-bitmap helpers (HFS, HFS+, ProDOS).
//! - `rust173` (feature `rust173-polyfill` only): extension traits standing in
//! for std methods missing on 1.73. Never enable it on a modern toolchain.
//!
//! With the `fs` feature (on by default), the interface every filesystem crate
//! (`fs-8bit`, `fs-mac`, …) implements:
//! - [`filesystem`]: `Filesystem` (read) and `EditableFilesystem` (write),
//! `FilesystemError`, create/repair options.
//! - [`entry`]: `FileEntry`, `EntryType` and directory display ordering.
//! - [`fsck`]: integrity-check results shared by every checker.
//! - [`times`]: Unix timestamps and the calendar conversions filesystems need.
//! - [`xattr`]: extended-attribute names and values.
//! - [`unix_common`]: inode, bitmap, compaction and validation helpers shared by Unix-style filesystems.
//!
//! Partition and disk-image crates depend on this with `default-features = false`
//! and so build without the filesystem types and their dependencies.
// `is_multiple_of` & co. come from the rust173 polyfill on 1.73; the real floor check is a 1.73 build.
/// Construct an `io::Error` of kind `Other` wrapping `error`.
///
/// Modern: `io::Error::other` (stable since Rust 1.74). Vintage (1.73): the
/// equivalent `io::Error::new(ErrorKind::Other, ..)`.
/// An iterator that repeats `value` exactly `count` times.
///
/// Modern: `iter::repeat_n` (stable since Rust 1.87). Vintage (1.73): the
/// equivalent `iter::repeat(value).take(count)`.