Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/ide/src/hover/tests.rs')
| -rw-r--r-- | crates/ide/src/hover/tests.rs | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/crates/ide/src/hover/tests.rs b/crates/ide/src/hover/tests.rs index 0139c04af8..50d0d4c5df 100644 --- a/crates/ide/src/hover/tests.rs +++ b/crates/ide/src/hover/tests.rs @@ -9465,4 +9465,39 @@ fn main() { size = 0, align = 1 "#]], ); + + check( + r#" +//- minicore: eq +pub struct RandomState; +pub struct HashMap<K, V, S = RandomState>(K, V, S); + +impl<K, V> HashMap<K, V, RandomState> { + pub fn new() -> HashMap<K, V, RandomState> { + loop {} + } +} + +impl<K, V, S> PartialEq for HashMap<K, V, S> { + fn eq(&self, other: &HashMap<K, V, S>) -> bool { + false + } +} + +fn main() { + let s$0 = HashMap::<_, u64>::ne; +} +"#, + expect![[r#" + *s* + + ```rust + let s: fn ne<HashMap<{unknown}, u64>>(&HashMap<{unknown}, u64>, &HashMap<{unknown}, u64>) -> bool + ``` + + --- + + size = 0, align = 1 + "#]], + ); } |