|
4 | 4 | //! diagnostics with suggested fixes that can be applied to the files on the
|
5 | 5 | //! filesystem, and validate that those changes didn't break anything.
|
6 | 6 | //!
|
7 |
| -//! Cargo begins by launching a `LockServer` thread in the background to |
| 7 | +//! Cargo begins by launching a [`LockServer`] thread in the background to |
8 | 8 | //! listen for network connections to coordinate locking when multiple targets
|
9 | 9 | //! are built simultaneously. It ensures each package has only one fix running
|
10 | 10 | //! at once.
|
11 | 11 | //!
|
12 |
| -//! The `RustfixDiagnosticServer` is launched in a background thread (in |
| 12 | +//! The [`RustfixDiagnosticServer`] is launched in a background thread (in |
13 | 13 | //! `JobQueue`) to listen for network connections to coordinate displaying
|
14 | 14 | //! messages to the user on the console (so that multiple processes don't try
|
15 | 15 | //! to print at the same time).
|
16 | 16 | //!
|
17 | 17 | //! Cargo begins a normal `cargo check` operation with itself set as a proxy
|
18 |
| -//! for rustc by setting `primary_unit_rustc` in the build config. When |
| 18 | +//! for rustc by setting `BuildConfig::primary_unit_rustc` in the build config. When |
19 | 19 | //! cargo launches rustc to check a crate, it is actually launching itself.
|
20 |
| -//! The `FIX_ENV_INTERNAL` environment variable is set so that cargo knows it is in |
21 |
| -//! fix-proxy-mode. |
| 20 | +//! The `FIX_ENV_INTERNAL` environment variable is set to the value of the [`LockServer`]'s |
| 21 | +//! address so that cargo knows it is in fix-proxy-mode. |
22 | 22 | //!
|
23 | 23 | //! Each proxied cargo-as-rustc detects it is in fix-proxy-mode (via `FIX_ENV_INTERNAL`
|
24 | 24 | //! environment variable in `main`) and does the following:
|
25 | 25 | //!
|
26 |
| -//! - Acquire a lock from the `LockServer` from the master cargo process. |
27 |
| -//! - Launches the real rustc (`rustfix_and_fix`), looking at the JSON output |
| 26 | +//! - Acquire a lock from the [`LockServer`] from the master cargo process. |
| 27 | +//! - Launches the real rustc ([`rustfix_and_fix`]), looking at the JSON output |
28 | 28 | //! for suggested fixes.
|
29 | 29 | //! - Uses the `rustfix` crate to apply the suggestions to the files on the
|
30 | 30 | //! file system.
|
|
0 commit comments