macro_rules! dos_main {
($($t:tt)*) => { ... };
}Expand description
Declares and defines the main application function.
This macro can be used as an alternative to declaring dosmain manually.
ยงExample
This:
#![no_main]
dos_like::dos_main! {
println!("Hello")
}Expands to this:
#![no_main]
#[no_mangle]
pub extern "C" fn dosmain(_argc: c_int, _argv: *const *const c_char) -> c_int {
println!("Hello");
0
}