ts.Accumulate(schema.SpawnUnion("TypeDefnInline",// n.b. previously called "TypeTerm".
...
...
@@ -170,6 +178,7 @@ func init() {
))
ts.Accumulate(schema.SpawnStruct("TypeUnion",
[]schema.StructField{
// n.b. we could conceivably allow TypeNameOrInlineDefn here rather than just TypeName. but... we'd rather not: imagine what that means about the type-level behavior of the union: the name munge for the anonymous type would suddenly become load-bearing. would rather not.
schema.SpawnStructField("members","List__TypeName",false,false),// todo: this is a slight hack: should be using an inline defn, but we banged it with name munge coincidents to simplify bootstrap.
schema.SpawnStructField("optional","Bool",false,false),// todo: wants to use the "implicit" feature, but not supported yet
schema.SpawnStructField("nullable","Bool",false,false),// todo: wants to use the "implicit" feature, but not supported yet
},
...
...
@@ -308,7 +317,7 @@ func init() {
))
ts.Accumulate(schema.SpawnStruct("TypeEnum",
[]schema.StructField{
schema.SpawnStructField("type","Map__EnumValue__Unit",false,false),// todo: dodging inline defn's again. also: this says unit; schema-schema does not. schema-schema needs revisiting on this subject.
schema.SpawnStructField("members","Map__EnumValue__Unit",false,false),// todo: dodging inline defn's again. also: this says unit; schema-schema does not. schema-schema needs revisiting on this subject.