rust/crates
bors 57cc2a6e27 Auto merge of #13602 - lowr:fix/nameres-transitive-visibility, r=Veykril
fix: check visibility of each path segment

Upon path resolution, we have not been checking if every def pointed to by each segment of the path is visible from the original module. This leads to incorrect import resolutions, in particular when one uses glob imports and names collide.

There is decent amount of changes in this PR because:
- some of our tests were not correct in terms of visibility
  - I left several basic nameres tests as-is (with expect test updated) since I thought it would be nice to ensure we don't resolve defs that are not visible.
- `fix_visibility` assist relied on `Semantics::resolve_path()`, which uses the name resolution procedure I'm fixing and wouldn't be able to "see through" the items with strict visibility with this patch

The first commit is the gist of the fix itself.

Fixes #10991
Fixes #11473
Fixes #13252
2022-11-11 12:32:21 +00:00
..
base-db Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
cfg Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
flycheck Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
hir Don't canonicalize self type when querying FnOnce signature 2022-11-08 18:05:07 +01:00
hir-def Auto merge of #13602 - lowr:fix/nameres-transitive-visibility, r=Veykril 2022-11-11 12:32:21 +00:00
hir-expand Auto merge of #13548 - lowr:fix/tt-punct-spacing, r=Veykril 2022-11-11 12:19:30 +00:00
hir-ty Fix tests that depended on loose visibility restriction 2022-11-11 20:31:46 +09:00
ide Fix tests that depended on loose visibility restriction 2022-11-11 20:31:46 +09:00
ide-assists Fix tests that depended on loose visibility restriction 2022-11-11 20:31:46 +09:00
ide-completion fix: Fix item completions not working properly after unit structs and outline modules 2022-11-08 08:37:45 +01:00
ide-db Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
ide-diagnostics Fix tests that depended on loose visibility restriction 2022-11-11 20:31:46 +09:00
ide-ssr Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
limit Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
mbe Auto merge of #13548 - lowr:fix/tt-punct-spacing, r=Veykril 2022-11-11 12:19:30 +00:00
parser Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
paths Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
proc-macro-api Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
proc-macro-srv Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
proc-macro-srv-cli Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
proc-macro-test Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
profile Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
project-model Add proc-macro dependency to rustc_private crates 2022-11-09 20:50:18 +01:00
rust-analyzer Send status notification if there are no found workspaces 2022-11-11 13:00:22 +01:00
sourcegen Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
stdx Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
syntax Auto merge of #13568 - noritada:fix/len-of-byte-string-with-escaped-newlines, r=Veykril 2022-11-07 15:04:40 +00:00
test-utils Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
text-edit Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
toolchain Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
tt Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
vfs Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00
vfs-notify Bump Cargo rust-version fields to latest stable 2022-11-07 12:59:51 +01:00