diff options
| author | bors <bors@rust-lang.org> | 2024-08-19 14:17:07 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2024-08-19 14:17:07 +0000 |
| commit | f9c0c8a7794b9a9679a82e95a8af67ba62948582 (patch) | |
| tree | e9bc4cb2edf275aade3284ddd1f7e578033c2eff /tests/codegen/patchable-function-entry | |
| parent | f17e9a0ffcc6e90058081a185bc45ef3a558a6b7 (diff) | |
| parent | ea12d79b3aaf025425b6a3043f38dc7454eda252 (diff) | |
| download | rust-f9c0c8a7794b9a9679a82e95a8af67ba62948582.tar.gz rust-f9c0c8a7794b9a9679a82e95a8af67ba62948582.zip | |
Auto merge of #17924 - ShoyuVanilla:issue-17921, r=Veykril
fix: Panic when a TAIT exists in a RPIT
Fixes #17921
When there is a TAIT inside of a RPIT like;
```rust
trait Foo {}
type Bar = impl Foo;
fn foo<A>() -> impl Future<Output = Bar> { .. }
```
while inferencing `fn foo`, `insert_inference_vars_for_impl_trait` tries to substitute impl trait bounds of `Bar`, i.e. `Implemented(Foo)` with RPITs `placeholders`, and this causes panic
https://github.com/rust-lang/rust-analyzer/blob/fa003262474185fd62168379500fe906b331824b/crates/hir-ty/src/infer.rs#L903-L905
Diffstat (limited to 'tests/codegen/patchable-function-entry')
0 files changed, 0 insertions, 0 deletions
