Skip to content

Commit 28d6062

Browse files
committed
Change the hypothetical rand version number to be actually hypothetical
Now that rand 0.9 actually exists 😅 Hopefully version 0.999.0 won't exist for a while!! This should address some of the confusion in #4508 and shouldn't need further updating even as rand's version increases (unless they go to 1.0 😳)
1 parent 5315789 commit 28d6062

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

src/ch02-00-guessing-game-tutorial.md

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -478,7 +478,7 @@ which will ignore the _Cargo.lock_ file and figure out all the latest versions
478478
that fit your specifications in _Cargo.toml_. Cargo will then write those
479479
versions to the _Cargo.lock_ file. Otherwise, by default, Cargo will only look
480480
for versions greater than 0.8.5 and less than 0.9.0. If the `rand` crate has
481-
released the two new versions 0.8.6 and 0.9.0, you would see the following if
481+
released the two new versions 0.8.6 and 0.999.0, you would see the following if
482482
you ran `cargo update`:
483483

484484
<!-- manual-regeneration
@@ -491,17 +491,19 @@ as a guide to creating the hypothetical output shown here -->
491491
$ cargo update
492492
Updating crates.io index
493493
Locking 1 package to latest Rust 1.85.0 compatible version
494-
Updating rand v0.8.5 -> v0.8.6 (available: v0.9.0)
494+
Updating rand v0.8.5 -> v0.8.6 (available: v0.999.0)
495495
```
496496

497-
Cargo ignores the 0.9.0 release. At this point, you would also notice a change
498-
in your _Cargo.lock_ file noting that the version of the `rand` crate you are
499-
now using is 0.8.6. To use `rand` version 0.9.0 or any version in the 0.9._x_
500-
series, you’d have to update the _Cargo.toml_ file to look like this instead:
497+
Cargo ignores the 0.999.0 release. At this point, you would also notice a
498+
change in your _Cargo.lock_ file noting that the version of the `rand` crate
499+
you are now using is 0.8.6. To use `rand` version 0.999.0 or any version in the
500+
0.999._x_ series, you’d have to update the _Cargo.toml_ file to look like this
501+
instead (don’t actually make this change because the following examples assume
502+
you’re using `rand` 0.8):
501503

502504
```toml
503505
[dependencies]
504-
rand = "0.9.0"
506+
rand = "0.999.0"
505507
```
506508

507509
The next time you run `cargo build`, Cargo will update the registry of crates

0 commit comments

Comments
 (0)