Skip to content

Commit 079f4d1

Browse files
committed
docs(ref): Update unstable docs for msrv-policy
1 parent 91796b1 commit 079f4d1

File tree

1 file changed

+18
-2
lines changed

1 file changed

+18
-2
lines changed

src/doc/src/reference/unstable.md

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -327,8 +327,24 @@ Documentation updates:
327327
## msrv-policy
328328
- [#9930](https://github.com/rust-lang/cargo/issues/9930) (MSRV-aware resolver)
329329

330-
The `msrv-policy` feature enables experiments in MSRV-aware policy for cargo in
331-
preparation for an upcoming RFC.
330+
Catch-all unstable feature for MSRV-aware cargo features under
331+
[RFC 2495](https://github.com/rust-lang/rfcs/pull/2495).
332+
333+
### MSRV-aware cargo add
334+
335+
This was stabilized in 1.79 in [#13608](https://github.com/rust-lang/cargo/pull/13608).
336+
337+
### MSRV-aware resolver
338+
339+
By default, `-Zmsrv-policy` enables an MSRV-aware resolver.
340+
The resolver will prefer dependencies with a `package.rust-version` that is the same or older than your project's MSRV.
341+
Your project's MSRV is determined by taking the lowest `package.rust-version` set among your workspace members.
342+
If there is none set, your toolchain version will be used with the intent to pick up the version from rustup's `rust-toolchain.toml`, if present.
343+
344+
MSRV-incompatible dependencies can still be selected by:
345+
- Setting the dependency's version requirement too high
346+
- Specifying the version to `cargo update` with `--precise`
347+
- Passing `--ignore-rust-version`
332348

333349
## precise-pre-release
334350

0 commit comments

Comments
 (0)