Skip to content

Commit 71a76ed

Browse files
committed
directive validation consistency edits
- add requirement that DirectiveLocations is non empty - Validation -> TypeValidation - s/directive/Directive in most places
1 parent 4ab71e3 commit 71a76ed

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

spec/Section 3 -- Type System.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2033,19 +2033,20 @@ directive @invalidExample(arg: String @invalidExample) on ARGUMENT_DEFINITION
20332033
Note: The order in which directives appear may be significant, including
20342034
repeatable directives.
20352035

2036-
**Validation**
2036+
**Type Validation**
20372037

2038-
1. A directive definition must not contain the use of a directive which
2038+
1. A Directive definition must include at least one DirectiveLocation
2039+
2. A Directive definition must not contain the use of a Directive which
20392040
references itself directly.
2040-
2. A directive definition must not contain the use of a directive which
2041+
3. A Directive definition must not contain the use of a Directive which
20412042
references itself indirectly by referencing a Type or Directive which
20422043
transitively includes a reference to this directive.
2043-
3. The directive must not have a name which begins with the characters {"\_\_"}
2044+
4. The Directive must not have a name which begins with the characters {"\_\_"}
20442045
(two underscores).
2045-
4. For each argument of the directive:
2046+
5. For each argument of the Directive:
20462047
1. The argument must not have a name which begins with the characters
20472048
{"\_\_"} (two underscores).
2048-
2. The argument must have a unique name within that directive; no two
2049+
2. The argument must have a unique name within that Directive; no two
20492050
arguments may share the same name.
20502051
3. The argument must accept a type where {IsInputType(argumentType)} returns
20512052
{true}.

0 commit comments

Comments
 (0)