1 # we require the discriminator to be a string naming a base-type member
2 # this tests the old syntax for anonymous unions before we added alternates
4 'data': [ 'value1', 'value2' ] }
5 { 'struct': 'TestBase',
6 'data': { 'enum1': 'TestEnum', 'kind': 'str' } }
7 { 'struct': 'TestTypeA',
8 'data': { 'string': 'str' } }
9 { 'struct': 'TestTypeB',
10 'data': { 'integer': 'int' } }
11 { 'union': 'TestUnion',
14 'data': { 'kind1': 'TestTypeA',
15 'kind2': 'TestTypeB' } }