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
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at https://mozilla.org/MPL/2.0/.
// Copyright (c) 2026 2youg1 and the sprawling contributors
//! Where one member of one backlog keeps its output while it runs.
//!
//! **A [`BacklogId`] cannot name this directory, and that is the whole
//! reason this module has a name of its own.** An id identifies a member
//! inside one backlog and starts again at one in the next; a directory
//! sits in a temp directory every backlog on the machine shares. Naming
//! it `sprawling-<pid>-<id>` assumed the id was unique per process, and
//! two backlogs of one process then collided on their first command each
//! (`crates/runtime/spec/Backlog.lean` ยง8-40).
use ;
use BacklogId;
/// How many backlogs this process has opened.
static BACKLOGS: AtomicU64 = new;
/// One backlog's claim on the machine's temp directory.
///
/// `Copy`, and carried by every clone of a [`Backlog`](super::Backlog):
/// two handles onto one backlog keep naming its directories, while two
/// backlogs opened separately never name each other's.
pub ;