Skip to content

Commit fd78bf1

Browse files
authored
Clarify: union types require at least one member type (#441)
1 parent b1d308b commit fd78bf1

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

spec/Section 3 -- Type System.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1161,10 +1161,11 @@ Unions are never valid inputs.
11611161

11621162
Union types have the potential to be invalid if incorrectly defined.
11631163

1164-
1. The member types of a Union type must all be Object base types;
1164+
1. A Union type must include one or more member types.
1165+
2. The member types of a Union type must all be Object base types;
11651166
Scalar, Interface and Union types must not be member types of a Union.
11661167
Similarly, wrapping types must not be member types of a Union.
1167-
2. A Union type must define one or more unique member types.
1168+
3. A Union type must define one or more unique member types.
11681169

11691170

11701171
### Union Extensions
@@ -1359,7 +1360,7 @@ Literal Value | Variables | Coerced Value
13591360

13601361
**Type Validation**
13611362

1362-
1. An Input Object type must define one or more fields.
1363+
1. An Input Object type must define one or more input fields.
13631364
2. The fields of an Input Object type must have unique names within that
13641365
Input Object type; no two fields may share the same name.
13651366
3. The return types of each defined field must be an Input type.

0 commit comments

Comments
 (0)