mirror of
https://github.com/notohh/rustlings.git
synced 2024-11-22 14:02:22 -05:00
2cdd61294f
The `watch` command now requires user action to move to the next exercise. BREAKING CHANGE: this changes the behavior of `watch`.
66 lines
405 B
Rust
66 lines
405 B
Rust
// macros1.rs
|
|
// Make me compile! Scroll down for hints :)
|
|
|
|
// I AM NOT DONE
|
|
|
|
macro_rules! my_macro {
|
|
() => {
|
|
println!("Check out my macro!");
|
|
};
|
|
}
|
|
|
|
fn main() {
|
|
my_macro();
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// When you call a macro, you need to add something special compared to a
|
|
// regular function call. If you're stuck, take a look at what's inside
|
|
// `my_macro`.
|