Skip to content

armgit / xerj

Public Imported from GitHub
0

AI search engine and MCP server for bots and agents. One Rust binary indexes code, docs, logs, JSONL/CSV and PDFs for BM25 full-text, vector and hybrid search, code search without grep, agent memory and RAG. Elasticsearch-compatible API; Corpus Hub serves hundreds of reference memory corpora.

fix(query): field-group scope inherits clause leniency (#1284/#1298 merge)

xerj-org4ac8ce3cf6ab
diff --git a/engine/crates/xerj-query/src/parser.rs b/engine/crates/xerj-query/src/parser.rs
index 5cd95daee..818271f14 100644
--- a/engine/crates/xerj-query/src/parser.rs
+++ b/engine/crates/xerj-query/src/parser.rs
@@ -2169,6 +2169,10 @@ fn parse_qs_unary(
let scoped = QsFields {
default_field: Some(&field),
fields: &[],
+ // Leniency is decided once per `query_string`, not per clause
+ // (#1284), so the scoped group inherits the enclosing clause's
+ // `lenient` just like any other leaf it lowers to.
+ lenient: ctx.lenient,
};
parse_qs_unary(toks, pos, scoped, default_op)
}