We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6b250a2 commit d1bdebfCopy full SHA for d1bdebf
crates/ide/src/goto_definition.rs
@@ -1977,6 +1977,33 @@ fn f() {
1977
);
1978
}
1979
1980
+ #[test]
1981
+ fn goto_deref_mut() {
1982
+ check(
1983
+ r#"
1984
+//- minicore: deref, deref_mut
1985
+
1986
+struct Foo;
1987
+struct Bar;
1988
1989
+impl core::ops::Deref for Foo {
1990
+ type Target = Bar;
1991
+ fn deref(&self) -> &Self::Target {}
1992
+}
1993
1994
+impl core::ops::DerefMut for Foo {
1995
+ fn deref_mut(&mut self) -> &mut Self::Target {}
1996
+ //^^^^^^^^^
1997
1998
1999
+fn f() {
2000
+ let a = Foo;
2001
+ $0*a = Bar;
2002
2003
+"#,
2004
+ );
2005
+ }
2006
2007
#[test]
2008
fn goto_bin_op() {
2009
check(
0 commit comments