rust/tests/ui/async-await
Matthias Krüger b4b483574f
Rollup merge of #120360 - compiler-errors:afit-sized-lol, r=lcnr
Don't fire `OPAQUE_HIDDEN_INFERRED_BOUND` on sized return of AFIT

Conceptually, we should probably not fire `OPAQUE_HIDDEN_INFERRED_BOUND` for methods like:

```
trait Foo { async fn bar() -> Self; }
```

Even though we technically cannot prove that `Self: Sized`, which is one of the item bounds of the `Output` type in the `-> impl Future<Output = Sized>` from the async desugaring.

This is somewhat justifiable along the same lines as how we allow regular methods to return `-> Self` even though `Self` isn't sized.

Fixes #113538

(side-note: some days i wonder if we should just remove the `OPAQUE_HIDDEN_INFERRED_BOUND` lint... it does make me sad that we have non-well-formed types in signatures, though.)
2024-01-26 14:43:32 +01:00
..
2024-01-13 12:46:58 -05:00
2023-09-23 13:47:30 +00:00
2023-09-23 13:47:30 +00:00
2023-09-23 13:47:30 +00:00
2023-09-23 13:47:30 +00:00
2023-10-13 21:01:36 +00:00
2023-09-23 13:47:30 +00:00
2023-09-26 20:15:28 +00:00
2023-09-23 13:47:30 +00:00
2023-09-23 13:47:30 +00:00
2023-09-23 13:47:30 +00:00
2023-09-23 13:47:30 +00:00
2024-01-13 12:46:58 -05:00
2024-01-13 12:46:58 -05:00
2023-09-23 13:34:07 +00:00
2023-10-28 23:11:03 -07:00
2023-10-20 21:14:01 +00:00
2023-10-20 21:14:01 +00:00
2023-09-23 13:47:30 +00:00
2023-09-23 13:47:30 +00:00
2023-09-23 13:47:30 +00:00
2023-09-23 13:47:30 +00:00
2023-09-23 13:47:30 +00:00
2023-09-23 13:47:30 +00:00
2023-09-23 13:34:07 +00:00
2023-09-23 13:47:30 +00:00
2023-10-20 21:14:01 +00:00
2023-09-23 13:34:07 +00:00
2023-09-23 13:47:30 +00:00
2023-09-23 13:47:30 +00:00
2023-10-20 21:14:01 +00:00
2024-01-07 08:56:20 -08:00
2023-10-20 21:14:01 +00:00
2023-09-23 13:47:30 +00:00