summaryrefslogtreecommitdiffstats
path: root/tests/qapi-schema/flat-union-string-discriminator.err
diff options
context:
space:
mode:
authorMarkus Armbruster2019-09-27 15:46:17 +0200
committerMarkus Armbruster2019-09-28 17:17:18 +0200
commit7be6c511943613c60b3e5b640e09bdc916be3b65 (patch)
tree03764294007e38beb8f80df950e131b7eda50da5 /tests/qapi-schema/flat-union-string-discriminator.err
parentqapi: New QAPISourceInfo, replacing dict (diff)
downloadqemu-7be6c511943613c60b3e5b640e09bdc916be3b65.tar.gz
qemu-7be6c511943613c60b3e5b640e09bdc916be3b65.tar.xz
qemu-7be6c511943613c60b3e5b640e09bdc916be3b65.zip
qapi: Prefix frontend errors with an "in definition" line
We take pains to include the offending expression in error messages, e.g. tests/qapi-schema/alternate-any.json:2: alternate 'Alt' member 'one' cannot use type 'any' But not always: tests/qapi-schema/enum-if-invalid.json:2: 'if' condition must be a string or a list of strings Instead of improving them one by one, report the offending expression whenever it is known, like this: tests/qapi-schema/enum-if-invalid.json: In enum 'TestIfEnum': tests/qapi-schema/enum-if-invalid.json:2: 'if' condition must be a string or a list of strings Error messages that mention the offending expression become a bit redundant, e.g. tests/qapi-schema/alternate-any.json: In alternate 'Alt': tests/qapi-schema/alternate-any.json:2: alternate 'Alt' member 'one' cannot use type 'any' I'll take care of that later in this series. Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Message-Id: <20190927134639.4284-5-armbru@redhat.com>
Diffstat (limited to 'tests/qapi-schema/flat-union-string-discriminator.err')
-rw-r--r--tests/qapi-schema/flat-union-string-discriminator.err1
1 files changed, 1 insertions, 0 deletions
diff --git a/tests/qapi-schema/flat-union-string-discriminator.err b/tests/qapi-schema/flat-union-string-discriminator.err
index 200016bd5c..9bca7082bb 100644
--- a/tests/qapi-schema/flat-union-string-discriminator.err
+++ b/tests/qapi-schema/flat-union-string-discriminator.err
@@ -1 +1,2 @@
+tests/qapi-schema/flat-union-string-discriminator.json: In union 'TestUnion':
tests/qapi-schema/flat-union-string-discriminator.json:13: Discriminator 'kind' must be of enumeration type