xml-to-wire: fix handling of new_id without interface
This commit is contained in:
parent
66efc946b6
commit
01fc2f128d
2 changed files with 5 additions and 1 deletions
|
|
@ -2,7 +2,7 @@ request bind {
|
|||
name: u32,
|
||||
interface: str,
|
||||
version: u32,
|
||||
id: id(object),
|
||||
id: id(object) (new),
|
||||
}
|
||||
|
||||
event global {
|
||||
|
|
|
|||
|
|
@ -90,6 +90,10 @@ fn handle_file_(path: &str) -> Result<(), BuilderError> {
|
|||
args.next();
|
||||
continue;
|
||||
}
|
||||
if arg.ty == ArgType::NewId && arg.interface.is_none() {
|
||||
writeln!(file, " interface: str,")?;
|
||||
writeln!(file, " version: u32,")?;
|
||||
}
|
||||
write!(file, " {}: ", arg.name)?;
|
||||
'ty: {
|
||||
let ty = match arg.ty {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue