&self
Rust
tips
impl
pub
fn
The first parameter
self
&self
&mut self
MOVE
struct
field
member
variable
borrow
reference
ä¸»é¡ Rust ã® impl 㪠fn ã®ç¬¬1å¼æ°ãã¤ã¾ã: struct S { } impl S { fn f(â¤ããâ¤) { } } â¤ãã⤠ã®é¨åã®æ¸ãæ¹ã¨ãæ¸ãæ¹ã«å¿ãã¦ã©ã®ãããªå¹æãæå³ã¨ãã¦æ±ããããããæ´çãã¾ãã fn f() fn f(self) fn f(mut self) fn f(&self) fn f(&mut self) ãâ¦