From 71a76edd98f7bad13e88371c10bc7805779d850a Mon Sep 17 00:00:00 2001 From: James Bellenger Date: Tue, 2 Apr 2024 06:00:57 -0700 Subject: [PATCH 1/3] directive validation consistency edits - add requirement that DirectiveLocations is non empty - Validation -> TypeValidation - s/directive/Directive in most places --- spec/Section 3 -- Type System.md | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/spec/Section 3 -- Type System.md b/spec/Section 3 -- Type System.md index af6a6244c..ec060218b 100644 --- a/spec/Section 3 -- Type System.md +++ b/spec/Section 3 -- Type System.md @@ -2033,19 +2033,20 @@ directive @invalidExample(arg: String @invalidExample) on ARGUMENT_DEFINITION Note: The order in which directives appear may be significant, including repeatable directives. -**Validation** +**Type Validation** -1. A directive definition must not contain the use of a directive which +1. A Directive definition must include at least one DirectiveLocation +2. A Directive definition must not contain the use of a Directive which references itself directly. -2. A directive definition must not contain the use of a directive which +3. A Directive definition must not contain the use of a Directive which references itself indirectly by referencing a Type or Directive which transitively includes a reference to this directive. -3. The directive must not have a name which begins with the characters {"\_\_"} +4. The Directive must not have a name which begins with the characters {"\_\_"} (two underscores). -4. For each argument of the directive: +5. For each argument of the Directive: 1. The argument must not have a name which begins with the characters {"\_\_"} (two underscores). - 2. The argument must have a unique name within that directive; no two + 2. The argument must have a unique name within that Directive; no two arguments may share the same name. 3. The argument must accept a type where {IsInputType(argumentType)} returns {true}. From cb28e5edc2c919fca97d539d77adda89d6b87d20 Mon Sep 17 00:00:00 2001 From: James Bellenger Date: Tue, 2 Apr 2024 06:27:09 -0700 Subject: [PATCH 2/3] add missing period --- spec/Section 3 -- Type System.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spec/Section 3 -- Type System.md b/spec/Section 3 -- Type System.md index ec060218b..2613effcd 100644 --- a/spec/Section 3 -- Type System.md +++ b/spec/Section 3 -- Type System.md @@ -2035,7 +2035,7 @@ repeatable directives. **Type Validation** -1. A Directive definition must include at least one DirectiveLocation +1. A Directive definition must include at least one DirectiveLocation. 2. A Directive definition must not contain the use of a Directive which references itself directly. 3. A Directive definition must not contain the use of a Directive which From c8ca2c124de7d9d772be7a30de658d130cb99643 Mon Sep 17 00:00:00 2001 From: Benjie Date: Tue, 14 May 2024 10:57:45 +0100 Subject: [PATCH 3/3] Update spec/Section 3 -- Type System.md --- spec/Section 3 -- Type System.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spec/Section 3 -- Type System.md b/spec/Section 3 -- Type System.md index 2613effcd..8beda1605 100644 --- a/spec/Section 3 -- Type System.md +++ b/spec/Section 3 -- Type System.md @@ -2040,7 +2040,7 @@ repeatable directives. references itself directly. 3. A Directive definition must not contain the use of a Directive which references itself indirectly by referencing a Type or Directive which - transitively includes a reference to this directive. + transitively includes a reference to this Directive. 4. The Directive must not have a name which begins with the characters {"\_\_"} (two underscores). 5. For each argument of the Directive: