Skip to main content

qualia_core_db/sparql_library/sparql_grammar/
mod.rs

1//! Recursive-descent SPARQL grammar — the parser front-end the engine was
2//! missing.
3//!
4//! The AST (`sparql_ast`), planner (`sparql_planner`), and executor
5//! (`sparql_executor` + `sparql_filter`) already implement the full SPARQL
6//! algebra: `Filter`, `Optional`, `Union`, `Minus`, `Bind`/`Project`,
7//! `GroupBy`, `Having`, `PropertyPath`, `Graph`, `Service`, `StarTripleScan`,
8//! and a complete `Expression` evaluator. What was missing was a parser that
9//! produces that AST from a query string — the legacy `sparql_parser.rs` only
10//! recognised a flat basic graph pattern. This module supplies the real thing,
11//! built in verified slices (see `docs/plans/sparql-full-implementation.md`).
12
13pub mod expr;
14pub mod pattern;
15pub mod tokenizer;
16pub mod update;
17
18pub use expr::parse_expression;
19pub use pattern::parse_where_group;
20pub use tokenizer::{tokenize, Token};
21pub use update::{is_update, parse_update};