From b08fc4382ac84f568954fb2d7bf36bbc210fc2d1 Mon Sep 17 00:00:00 2001 From: Romain Delamare Date: Sun, 14 Apr 2024 16:17:28 +0200 Subject: [PATCH] kql: only allow top() at start of selector --- QUERY-SPEC.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/QUERY-SPEC.md b/QUERY-SPEC.md index 114a75c..bd6a802 100644 --- a/QUERY-SPEC.md +++ b/QUERY-SPEC.md @@ -110,8 +110,9 @@ what they expand to. ``` query-str := $bom? query -query := selector q-ws* "||" q-ws* query | selector -selector := filter q-ws* selector-operator q-ws* selector | filter +query := selector-start q-ws* "||" q-ws* query | selector-start +selector-start := filter q-ws* selector-operator q-ws* selector | filter +selector := matchers q-ws* selector-operator q-ws* selector | matchers selector-operator := ">>" | ">" | "++" | "+" filter := "top(" q-ws* ")" | matchers matchers := type-matcher $string? accessor-matcher* | $string accessor-matcher* | accessor-matcher+