about summary refs log tree commit diff
path: root/tests/mir-opt/lower_array_len.array_len_raw.NormalizeArrayLen.diff
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2023-01-25 22:19:51 +0100
committerGitHub <noreply@github.com>2023-01-25 22:19:51 +0100
commitf21728fee4eb11ec7e73801bc60e78dbb08bf71a (patch)
treeb52492509b83c46bb47eddd23be2d380091ab3c2 /tests/mir-opt/lower_array_len.array_len_raw.NormalizeArrayLen.diff
parent027c8507b4265dcf285b0b503e2a49214b929f7b (diff)
parent62a1e76d2beaa87d7f02a55e2d7faa03cdd5fd7f (diff)
downloadrust-f21728fee4eb11ec7e73801bc60e78dbb08bf71a.tar.gz
rust-f21728fee4eb11ec7e73801bc60e78dbb08bf71a.zip
Rollup merge of #105345 - yanchen4791:issue-103582-fix, r=jackh726
Add hint for missing lifetime bound on trait object when type alias is used

Fix issue #103582.

The problem: When a type alias is used to specify the return type of the method in a trait impl, the suggestion for fixing the problem of "missing lifetime bound on trait object" of the trait impl will not be created. The issue caused by the code which searches for the return trait objects when constructing the hint suggestion is not able to find the trait objects since they are specified in the type alias path instead of the return path of the trait impl.

The solution: Trace the trait objects in the type alias path and provide them along with the alias span to generate the suggestion in case the type alias is used in return type of the method in the trait impl.
Diffstat (limited to 'tests/mir-opt/lower_array_len.array_len_raw.NormalizeArrayLen.diff')
0 files changed, 0 insertions, 0 deletions