xmlgen: Fails for property with name matching keyword
zbus-xmlgen --system org.freedesktop.UDisks2 /org/freedesktop/UDisks2/block_devices/nvme0n1p1
error: expected identifier, found keyword `type`
--> <stdin>:109:8
|
109 | fn type(&self) -> zbus::Result<String>;
| ^^^^ expected identifier, found keyword
|
help: you can escape reserved keywords to use them as identifiers
|
109 | fn r#type(&self) -> zbus::Result<String>;
| ^^^^^^
Perhaps appending _
would be an idiomatic solution for this.
Edited by Ian Douglas Scott