Skip to content

Instantly share code, notes, and snippets.

@mcpherrinm
Created March 11, 2013 03:08
Show Gist options
  • Save mcpherrinm/5131644 to your computer and use it in GitHub Desktop.
Save mcpherrinm/5131644 to your computer and use it in GitHub Desktop.
#[link(name = "bar", vers = "0.0", author = "otters")];
pub fn foobar() {
io::println("baz");
}
11:07pm syrup:~% rustc --lib bar.rs
11:07pm syrup:~% rustc -L . foo.rs
11:07pm syrup:~% ./foo
baz
extern mod bar;
fn main() {
bar::foobar();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment