diff options
| author | Vadim Petrochenkov <vadim.petrochenkov@gmail.com> | 2024-05-10 17:29:02 +0300 |
|---|---|---|
| committer | Vadim Petrochenkov <vadim.petrochenkov@gmail.com> | 2024-05-22 18:02:51 +0300 |
| commit | 711338bd9f957b7bd345323033e9037c0e1ca535 (patch) | |
| tree | 3ad83bd2c7bcee007c49752f517483e77eb53856 /src/librustdoc/scrape_examples.rs | |
| parent | f0038a7c8fd8b5b8a949c92ae6419bcb59a09e72 (diff) | |
| download | rust-711338bd9f957b7bd345323033e9037c0e1ca535.tar.gz rust-711338bd9f957b7bd345323033e9037c0e1ca535.zip | |
rustc: Use `tcx.used_crates(())` more
And explain when it should be used.
Diffstat (limited to 'src/librustdoc/scrape_examples.rs')
| -rw-r--r-- | src/librustdoc/scrape_examples.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/librustdoc/scrape_examples.rs b/src/librustdoc/scrape_examples.rs index 9c9b386edda..19b0e045f04 100644 --- a/src/librustdoc/scrape_examples.rs +++ b/src/librustdoc/scrape_examples.rs @@ -283,7 +283,7 @@ pub(crate) fn run( // Collect CrateIds corresponding to provided target crates // If two different versions of the crate in the dependency tree, then examples will be collected from both. let all_crates = tcx - .crates(()) + .crates_including_speculative(()) .iter() .chain([&LOCAL_CRATE]) .map(|crate_num| (crate_num, tcx.crate_name(*crate_num))) |
