uniffi-rs icon indicating copy to clipboard operation
uniffi-rs copied to clipboard

Support language-specific documentation in bindings

Open EATSTEAK opened this issue 5 months ago • 0 comments
trafficstars

Currently, uniffi supports generating bindings documentation using Rust doc comments. However, these comments cannot be conditionally included based on the target language (e.g. writing example in comments could be confusing to FFI users).

Would it be possible to support language-specific documentation?
For instance, something like #[uniffi(doc(language = "kotlin", doc = "Some comments only shown in Kotlin"))] (in proc macro),
or a more flexible approach to parsing doc comments conditionally per language.

EATSTEAK avatar Jun 08 '25 04:06 EATSTEAK