We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 460e389 + 956b8fb commit cc69536Copy full SHA for cc69536
crates/ide/src/signature_help.rs
@@ -129,7 +129,7 @@ fn signature_help_for_call(
129
hir::CallableKind::Function(func) => {
130
res.doc = func.docs(db).map(|it| it.into());
131
format_to!(res.signature, "fn {}", func.name(db));
132
- fn_params = Some(match func.self_param(db) {
+ fn_params = Some(match callable.receiver_param(db) {
133
Some(_self) => func.params_without_self(db),
134
None => func.assoc_fn_params(db),
135
});
@@ -1142,4 +1142,20 @@ fn f() {
1142
"#]],
1143
);
1144
}
1145
+
1146
+ #[test]
1147
+ fn fully_qualified_syntax() {
1148
+ check(
1149
+ r#"
1150
+fn f() {
1151
+ trait A { fn foo(&self, other: Self); }
1152
+ A::foo(&self$0, other);
1153
+}
1154
+"#,
1155
+ expect![[r#"
1156
+ fn foo(self: &Self, other: Self)
1157
+ ^^^^^^^^^^^ -----------
1158
+ "#]],
1159
+ );
1160
+ }
1161
0 commit comments