diff mbox series

[05/28] tests/qapi-schema: Drop TODO comment on simple unions

Message ID 20210323094025.3569441-6-armbru@redhat.com (mailing list archive)
State New, archived
Headers show
Series qapi: Enforce naming rules | expand

Commit Message

Markus Armbruster March 23, 2021, 9:40 a.m. UTC
Simple unions don't need more features, they need to die.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
---
 tests/qapi-schema/flat-union-no-base.err  | 2 +-
 tests/qapi-schema/flat-union-no-base.json | 1 -
 2 files changed, 1 insertion(+), 2 deletions(-)

Comments

John Snow March 23, 2021, 1:16 p.m. UTC | #1
On 3/23/21 5:40 AM, Markus Armbruster wrote:
> Simple unions don't need more features, they need to die.
> 

I'm willing to defer to your will here.

(And I'm not willing to implement enum discriminators to spite you.)

> Signed-off-by: Markus Armbruster <armbru@redhat.com>

Reviewed-by: John Snow <jsnow@redhat.com>

> ---
>   tests/qapi-schema/flat-union-no-base.err  | 2 +-
>   tests/qapi-schema/flat-union-no-base.json | 1 -
>   2 files changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/tests/qapi-schema/flat-union-no-base.err b/tests/qapi-schema/flat-union-no-base.err
> index 9bd595bcfb..5167565b00 100644
> --- a/tests/qapi-schema/flat-union-no-base.err
> +++ b/tests/qapi-schema/flat-union-no-base.err
> @@ -1,2 +1,2 @@
>   flat-union-no-base.json: In union 'TestUnion':
> -flat-union-no-base.json:9: 'discriminator' requires 'base'
> +flat-union-no-base.json:8: 'discriminator' requires 'base'
> diff --git a/tests/qapi-schema/flat-union-no-base.json b/tests/qapi-schema/flat-union-no-base.json
> index ffc4c6f0e6..327877b563 100644
> --- a/tests/qapi-schema/flat-union-no-base.json
> +++ b/tests/qapi-schema/flat-union-no-base.json
> @@ -1,5 +1,4 @@
>   # flat unions require a base
> -# TODO: simple unions should be able to use an enum discriminator
>   { 'struct': 'TestTypeA',
>     'data': { 'string': 'str' } }
>   { 'struct': 'TestTypeB',
>
diff mbox series

Patch

diff --git a/tests/qapi-schema/flat-union-no-base.err b/tests/qapi-schema/flat-union-no-base.err
index 9bd595bcfb..5167565b00 100644
--- a/tests/qapi-schema/flat-union-no-base.err
+++ b/tests/qapi-schema/flat-union-no-base.err
@@ -1,2 +1,2 @@ 
 flat-union-no-base.json: In union 'TestUnion':
-flat-union-no-base.json:9: 'discriminator' requires 'base'
+flat-union-no-base.json:8: 'discriminator' requires 'base'
diff --git a/tests/qapi-schema/flat-union-no-base.json b/tests/qapi-schema/flat-union-no-base.json
index ffc4c6f0e6..327877b563 100644
--- a/tests/qapi-schema/flat-union-no-base.json
+++ b/tests/qapi-schema/flat-union-no-base.json
@@ -1,5 +1,4 @@ 
 # flat unions require a base
-# TODO: simple unions should be able to use an enum discriminator
 { 'struct': 'TestTypeA',
   'data': { 'string': 'str' } }
 { 'struct': 'TestTypeB',