about summary refs log tree commit diff
path: root/compiler/rustc_interface/src
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2022-07-11 22:39:09 +0200
committerGitHub <noreply@github.com>2022-07-11 22:39:09 +0200
commit5e223dc7b9b541e12514efeb05b915af9b6e508c (patch)
treec2a2f772f58b7e7076179859d9f9baf06d11dc63 /compiler/rustc_interface/src
parent1679d1c6223aaf0e946291aca66f5dbf1396ab08 (diff)
parent88f2140d8736329610a4c0bd8000e164c9170537 (diff)
downloadrust-5e223dc7b9b541e12514efeb05b915af9b6e508c.tar.gz
rust-5e223dc7b9b541e12514efeb05b915af9b6e508c.zip
Rollup merge of #99146 - compiler-errors:issue-61525, r=lcnr
Do not error during method probe on `Sized` predicates for types that aren't the method receiver

Fixes #61525

This is safe even though we're skipping an error because we end up confirming the method, which means we're still checking the `Sized` predicate in the end. It just means that we don't emit an erroneous message as below:

```
error: the `query` method cannot be invoked on a trait object
  --> src/lib.rs:14:11
   |
14 |         1.query::<dyn ToString>("")
   |           ^^^^^
   |
   = note: another candidate was found in the following trait, perhaps add a `use` for it:
           `use crate::Example;`
```

Also fixes erroneously suggesting the same trait over again, as seen in the `issue-35976.rs` UI test.
Diffstat (limited to 'compiler/rustc_interface/src')
0 files changed, 0 insertions, 0 deletions