aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rw-r--r--scripts/qapi.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/scripts/qapi.py b/scripts/qapi.py
index 84e2eb441b..8aa2775f12 100644
--- a/scripts/qapi.py
+++ b/scripts/qapi.py
@@ -20,6 +20,7 @@ import sys
from ordereddict import OrderedDict
builtin_types = {
+ 'null': 'QTYPE_QNULL',
'str': 'QTYPE_QSTRING',
'int': 'QTYPE_QNUM',
'number': 'QTYPE_QNUM',
@@ -1056,6 +1057,7 @@ class QAPISchemaType(QAPISchemaEntity):
def alternate_qtype(self):
json2qtype = {
+ 'null': 'QTYPE_QNULL',
'string': 'QTYPE_QSTRING',
'number': 'QTYPE_QNUM',
'int': 'QTYPE_QNUM',
@@ -1515,7 +1517,8 @@ class QAPISchema(object):
('uint64', 'int', 'uint64_t'),
('size', 'int', 'uint64_t'),
('bool', 'boolean', 'bool'),
- ('any', 'value', 'QObject' + pointer_suffix)]:
+ ('any', 'value', 'QObject' + pointer_suffix),
+ ('null', 'null', 'QNull' + pointer_suffix)]:
self._def_builtin_type(*t)
self.the_empty_object_type = QAPISchemaObjectType(
'q_empty', None, None, None, [], None)