Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,11 @@ name = "ldbc_bench"
path = "src/bin/ldbc_bench.rs"
required-features = ["bench"]

[[bin]]
name = "scenario_bench"
path = "src/bin/scenario_bench.rs"
required-features = ["bench"]

[workspace]
members = [".", "python", "node", "wasm"]
# resolver = "2" computes features per-target instead of unifying them
Expand Down
32 changes: 32 additions & 0 deletions src/bin/pattern_typecheck.rs
Original file line number Diff line number Diff line change
Expand Up @@ -360,6 +360,38 @@ fn main() {
"valid".into(),
"(p: Person)~[:knows]~{2,4}(f: Person)".into(),
));
// Full-surface cases: the legacy `bench` set is patterns-only by
// design (it mirrors the Python reference checker, which supported
// only path patterns — right shape, but not the queries users type).
// These exercise RETURN typing, ORDER BY, aggregates, and the
// multi-MATCH collapse path.
cases.push((
"full_return_orderby".into(),
"full".into(),
"valid".into(),
"MATCH (p: Person)~[:knows]~(f: Person) WHERE p.id = 933 \
RETURN f.firstName ORDER BY f.firstName LIMIT 10"
.into(),
));
cases.push((
"full_count".into(),
"full".into(),
"valid".into(),
"MATCH (m: Comment)-[:hasCreator]->(p: Person) RETURN COUNT(m)".into(),
));
cases.push((
"full_multi_match".into(),
"full".into(),
"valid".into(),
"MATCH (p: Person)~[:knows]~(f: Person) MATCH (f)~[:knows]~(g: Person) RETURN g.id".into(),
));
cases.push((
"full_alias_orderby".into(),
"full".into(),
"valid".into(),
"MATCH (p: Person)~[:knows]~(f: Person) RETURN f.firstName AS name ORDER BY name LIMIT 5"
.into(),
));
cases.push((
"subq_exists".into(),
"subq".into(),
Expand Down
Loading