about summary refs log tree commit diff
path: root/compiler/rustc_llvm/llvm-wrapper/CoverageMappingWrapper.cpp
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2022-10-11 18:59:45 +0200
committerGitHub <noreply@github.com>2022-10-11 18:59:45 +0200
commit6d58ff7fe6d81a6fd7b8a09f720617f1e2c62819 (patch)
tree62114069826fdd59f87b3d66d8ca5e8f3829a518 /compiler/rustc_llvm/llvm-wrapper/CoverageMappingWrapper.cpp
parentcde693cf962f0f606e33eb21242f6bcd2d8d8b7a (diff)
parent152cd6322655bb5173655cdf0781ca64c2a7602f (diff)
downloadrust-6d58ff7fe6d81a6fd7b8a09f720617f1e2c62819.tar.gz
rust-6d58ff7fe6d81a6fd7b8a09f720617f1e2c62819.zip
Rollup merge of #100387 - cjgillot:hygiene-trait-impl, r=petrochenkov
Check uniqueness of impl items by trait item when applicable.

When checking uniqueness of item names in impl blocks, we currently use the same definition of hygiene as for toplevel items.  This means that a plain item and one generated by a macro 2.0 do not collide.

This hygiene rule does not match with how impl items resolve to associated trait items. As a consequence, we misdiagnose the trait impls.

This PR proposes to consider that trait impl items are uses of the corresponding trait items during resolution, instead of checking for duplicates later. An error is emitted when a trait impl item is used twice.

There should be no stable breakage, since macros 2.0 are still unstable.

r? ``@petrochenkov``
cc ``@RalfJung``

Fixes https://github.com/rust-lang/rust/issues/71614.
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper/CoverageMappingWrapper.cpp')
0 files changed, 0 insertions, 0 deletions