masterbongo_core 0.1.1

A dummy crate for testing cargo workspaces - core
Documentation
#![doc = include_str!("../README.md")]

/// This trait can be implemented using the derive macro
/// with the optional `derive` feature.
pub trait MasterBongo {
    /// Masterbongo the struct.
    fn masterbongo(&self);
}

/// Main function to masterbongo the user.
pub fn greet(msg: &str) {
    println!("Master Bongo: {}", msg);
}

/// Macro to masterbongo the user with multiple messages.
#[macro_export]
macro_rules! masterbongo {
    ($( $x:expr),* ) => {
        $(
            println!("Master Bongo: {}", $x);
        )*
    };
    () => {
        println!("Master Bongo: No message provided.");
    };
}

#[cfg(test)]
mod tests {
    use super::*;

    #[test]
    fn it_works() {
        greet("test");
        masterbongo!();
    }
}