save-analysis: Add a related test case
This commit is contained in:
parent
b456c820ff
commit
6117faa809
1 changed files with 23 additions and 0 deletions
23
src/test/ui/save-analysis/issue-63663.rs
Normal file
23
src/test/ui/save-analysis/issue-63663.rs
Normal file
|
@ -0,0 +1,23 @@
|
|||
// check-pass
|
||||
// compile-flags: -Zsave-analysis
|
||||
|
||||
// Check that this doesn't ICE when processing associated const in formal
|
||||
// argument and return type of functions defined inside function/method scope.
|
||||
|
||||
pub trait Trait {
|
||||
type Assoc;
|
||||
}
|
||||
|
||||
pub struct A;
|
||||
|
||||
pub fn func() {
|
||||
fn _inner1<U: Trait>(_: U::Assoc) {}
|
||||
fn _inner2<U: Trait>() -> U::Assoc { unimplemented!() }
|
||||
|
||||
impl A {
|
||||
fn _inner1<U: Trait>(self, _: U::Assoc) {}
|
||||
fn _inner2<U: Trait>(self) -> U::Assoc { unimplemented!() }
|
||||
}
|
||||
}
|
||||
|
||||
fn main() {}
|
Loading…
Reference in a new issue