From 4c10ce92041dc73a95aeb64aca241dd937ffaa5c Mon Sep 17 00:00:00 2001 From: Eugen Wissner Date: Mon, 14 Sep 2020 07:49:33 +0200 Subject: Use Seq as base monad in the validator It is more natural to implement the logic: try to apply each rule to each node. --- CHANGELOG.md | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'CHANGELOG.md') diff --git a/CHANGELOG.md b/CHANGELOG.md index 378814d..85ffcf1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,9 +10,16 @@ and this project adheres to ### Changed - `AST.Document.Selection` wraps additional new types: `Field`, `FragmentSpread` and `InlineFragment`. Thus validation rules can be defined more concise. +- `AST.Document.Argument` contains the argument location. +- `AST.Lexer.colon` ignores the result (it is always a colon). +- `Validate.Validation`: `Validation.rules` was removed. `Validation.rules` + contained the list of rules, but the executed rules shouldn't know about other + rules. `rules` was a part of the `Validation` context to pass it easier + around, but since the rules are traversed once now and applied to all nodes in + the tree at the beginning, it isn't required anymore. ### Added -- `Validate.Validation.Rule`: `SelectionRule`, `FieldRule`, `FragmentRule` and +- `Validate.Validation.Rule`: `SelectionRule`, `FieldRule`, `FragmentRule`, `FragmentSpreadRule` constructors. - `Validate.Rules`: - `fragmentsOnCompositeTypesRule` -- cgit v1.2.3