(node: unknown)
| 41 | * within. Used at parse time to pre-compute per-query state dependencies. |
| 42 | */ |
| 43 | export function collectQueryDeps(node: unknown): string[] { |
| 44 | if (!isASTNode(node)) return []; |
| 45 | const refs = new Set<string>(); |
| 46 | walkAST(node, (current) => { |
| 47 | if (current.k === "StateRef") refs.add(current.n); |
| 48 | }); |
| 49 | return [...refs]; |
| 50 | } |
| 51 | |
| 52 | /** |
| 53 | * Classify a raw statement + parsed expression into a typed Statement. |
no test coverage detected