Browse Source

Add snippet for fmt::Display implementation

coc
Schneider 5 years ago
parent
commit
84c3c4ea47
Signed by: schneider GPG Key ID: 3F50B02A50039F3B
  1. 9
      vim/neosnippets/rust.snip

9
vim/neosnippets/rust.snip

@ -2,3 +2,12 @@ snippet debug
abbr deb abbr deb
options head options head
println!("{:?}", ${1}); println!("{:?}", ${1});
snippet impldisplay
abbr disp
options head
impl fmt::Display for ${1} {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
write!(f, "${2}", ${3})
}
}
Loading…
Cancel
Save