Skip to content

Commit 6bc1264

Browse files
committed
Rollup merge of #26892 - steveklabnik:gh26482, r=alexcrichton
We weren't explicit enough about Cargo's default version behavior. For rust-lang/rust at least, Fixes #26482
2 parents bd1033d + 1ae7702 commit 6bc1264

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/doc/trpl/guessing-game.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -360,10 +360,12 @@ rand="0.3.0"
360360
The `[dependencies]` section of `Cargo.toml` is like the `[package]` section:
361361
everything that follows it is part of it, until the next section starts.
362362
Cargo uses the dependencies section to know what dependencies on external
363-
crates you have, and what versions you require. In this case, we’ve used version `0.3.0`.
363+
crates you have, and what versions you require. In this case, we’ve specified version `0.3.0`,
364+
which Cargo understands to be any release that’s compatible with this specific version.
364365
Cargo understands [Semantic Versioning][semver], which is a standard for writing version
365-
numbers. If we wanted to use the latest version we could use `*` or we could use a range
366-
of versions. [Cargo’s documentation][cargodoc] contains more details.
366+
numbers. If we wanted to use only `0.3.0` exactly, we could use `=0.3.0`. If we
367+
wanted to use the latest version we could use `*`; We could use a range of
368+
versions. [Cargo’s documentation][cargodoc] contains more details.
367369

368370
[semver]: http://semver.org
369371
[cargodoc]: http://doc.crates.io/crates-io.html

0 commit comments

Comments
 (0)