mirror of
https://gitlab.gnome.org/jwestman/blueprint-compiler.git
synced 2025-05-04 15:59:08 -04:00
Support array type
This commit is contained in:
parent
f1cf70b6eb
commit
da5b9909fc
16 changed files with 133 additions and 4 deletions
|
@ -139,6 +139,15 @@ class XmlOutput(OutputFormat):
|
|||
self._emit_object(value.object, xml)
|
||||
xml.end_tag()
|
||||
|
||||
elif isinstance(value, ArrayValue):
|
||||
xml.start_tag("property", **props)
|
||||
values = list(value.values)
|
||||
for value in values[:-1]:
|
||||
self._emit_value(value, xml)
|
||||
xml.put_text("\n")
|
||||
self._emit_value(values[-1], xml)
|
||||
xml.end_tag()
|
||||
|
||||
else:
|
||||
raise CompilerBugError()
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue