[][src]Macro gdnative_common::godot_gdnative_terminate

macro_rules! godot_gdnative_terminate {
    () => { ... };
    ($ callback : ident) => { ... };
    (_ as $ fn_name : ident) => { ... };
    ($ callback : ident as $ fn_name : ident) => { ... };
}

Declare the API endpoint invoked during shutdown.

By default this declares an extern function named godot_gdnative_terminate. This can be overridden, for example:

This example is not tested
// Declares an extern function named custom_gdnative_terminate instead of
// godot_gdnative_terminate.
godot_gdnative_terminate!(my_shutdown_callback as custom_gdnative_terminate);

Overriding the default entry point names can be useful if several gdnative libraries are linked statically to avoid name clashes.