Add a test case
This commit is contained in:
parent
55aee5470b
commit
f7096db910
1 changed files with 24 additions and 0 deletions
|
@ -3062,6 +3062,30 @@ fn f() {
|
|||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn into_call_to_from_definition_with_trait_bounds() {
|
||||
check(
|
||||
r#"
|
||||
//- minicore: from, iterator
|
||||
struct A;
|
||||
|
||||
impl<T> From<T> for A
|
||||
where
|
||||
T: IntoIterator<Item = i64>,
|
||||
{
|
||||
fn from(value: T) -> Self {
|
||||
//^^^^
|
||||
A
|
||||
}
|
||||
}
|
||||
|
||||
fn f() {
|
||||
let a: A = [1, 2, 3].into$0();
|
||||
}
|
||||
"#,
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn goto_into_definition_if_exists() {
|
||||
check(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue