Created
June 29, 2015 22:13
-
-
Save anonymous/1574815579a7cc9feb91 to your computer and use it in GitHub Desktop.
Shared via Rust Playground
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
struct X; | |
impl X { | |
fn foo(&self) { | |
println!("42") | |
} | |
} | |
fn main() { | |
let x = X; | |
x.foo(); | |
X::foo(&x) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment