21 lines
633 B
Rust
21 lines
633 B
Rust
extern crate proc_macro;
|
|
extern crate phrases as sayings;
|
|
extern crate syn;
|
|
#[macro_use]
|
|
extern crate quote;
|
|
|
|
use sayings::japanese::greetings as ja_greetings;
|
|
use sayings::japanese::farewells::*;
|
|
use sayings::english::{self, greetings as en_greetings, farewells as en_farewells};
|
|
|
|
extern "C" {
|
|
fn c_callback(n: c_int);
|
|
}
|
|
|
|
fn main() {
|
|
println!("Hello in English; {}", en_greetings::hello());
|
|
println!("And in Japanese: {}", ja_greetings::hello());
|
|
println!("Goodbye in English: {}", english::farewells::goodbye());
|
|
println!("Again: {}", en_farewells::goodbye());
|
|
println!("And in Japanese: {}", goodbye());
|
|
}
|