summaryrefslogtreecommitdiffstats
path: root/src/test/ui/save-analysis/issue-65590.rs
blob: 27874f8655e56c7bde9c5af7b305c75004c3d85c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
// check-pass
// compile-flags: -Zsave-analysis
// edition:2018

// Async desugaring for return types in (associated) functions introduces a
// separate definition internally, which we need to take into account
// (or else we ICE).
trait Trait { type Assoc; }
struct Struct;

async fn foobar<T: Trait>() -> T::Assoc {
    unimplemented!()
}

impl Struct {
    async fn foo<T: Trait>(&self) -> T::Assoc {
        unimplemented!()
    }
}

fn main() {}