about summary refs log tree commit diff
path: root/compiler/rustc_llvm/llvm-wrapper/CoverageMappingWrapper.cpp
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2023-03-01 12:40:55 +0000
committerbors <bors@rust-lang.org>2023-03-01 12:40:55 +0000
commit32424d0aba3f9e20576aff0a1c89e01ac3ad8b62 (patch)
treeec60bca941c682cfe7ab5cd4a43eec8f57ac6b0d /compiler/rustc_llvm/llvm-wrapper/CoverageMappingWrapper.cpp
parentef9d5db8571117911d8e039aed46fdff59bd65a2 (diff)
parentd4166234ef54a1019fe200adb414d0580133cd69 (diff)
downloadrust-32424d0aba3f9e20576aff0a1c89e01ac3ad8b62.tar.gz
rust-32424d0aba3f9e20576aff0a1c89e01ac3ad8b62.zip
Auto merge of #14176 - lowr:fix/assoc-func-vis-in-local-impl, r=Veykril
Fix associated item visibility in block-local impls

Fixes #14046

When we're resolving visibility of block-local items...

> `self` normally refers to the containing non-block module, and `super` to its parent (etc.). However, visibilities must only refer to a module in the DefMap they're written in, so we restrict them when that happens. ([link])

 ...unless we're resolving visibility of associated items in block-local impls, because that impl is semantically "hoisted" to the nearest (non-block) module. With this PR, we skip the adjustment for such items.

Since visibility representation of those items is modified, this PR also adjusts visibility rendering in `HirDisplay`.

[link]: https://github.com/rust-lang/rust-analyzer/blob/a6603fc21d50b3386a488c96225b2d1fd492e533/crates/hir-def/src/nameres/path_resolution.rs#L101-L103
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper/CoverageMappingWrapper.cpp')
0 files changed, 0 insertions, 0 deletions