ubolonton / emacs-module-rs

Rust binding and tools for Emacs's dynamic modules
340 stars 22 forks source link

Don't require modules to define an init function that does nothing #9

Open ubolonton opened 5 years ago

ubolonton commented 5 years ago

Often time, there's no initialization logic needed. Modules should be able to put #![emacs::module] at the root of the crate, instead of this:

// So much boilerplate!
#[emacs::module]
fn init(_: &Env) -> Result<()> {
    Ok(())
}

This needs to wait for Rust's issue #54726.