uniffi-rs
uniffi-rs copied to clipboard
Namespacing entities in generated bindings
Right now, at least when using proc macros, all entities are mangled into the same namespace in the generated bindings, even if they come from totally different modules in the source. This gets messy quickly when having lots of functions. Is there a plan to respect modules or e.g. customise the namespace of an exported binding with a macro?
Yeah, the foreign namespace is currently flat for a given crate. I'm not aware of any plans, so I think we'd welcome proposals, but I suspect there's not going to be an easy story to be told here. cross-crate module namespaces should work OK, and IMO that's more important and has the added advantage of encouraging smaller more module crates.