SDL3 main callbacks with rust bindgen

I have a very basic rust project using rust-bindgen to generate SDL3 rust bindings, everything good and basically mapped 1:1 from SDL C examples to rust except the main callbacks, seems the trick requires more than enabling SDL_MAIN_USE_CALLBACKS in bindgen wrapper.h

For some reasons there seem there is an entry point barrier to understand how this callback mechanism works in foreign languages like rust

Is it required to mark a function with a decorator besides being extern “C” ?

I’m also aware there is a sdl3_main crate. however that crate took a different approach by rejecting rust bindgen entirely and using it’s own binding generator