datalog: dl-eval source + query convenience (181/181)
Some checks failed
Test, Build, and Deploy / test-build-deploy (push) Failing after 23s

Single-call entry: dl-eval source-string query-string parses
both, builds a db via dl-program, saturates implicitly, runs
the query (extracted from the parsed `?- ...` clause), and
returns the substitution list.

Most user-friendly path:
  (dl-eval "parent(a, b). ..." "?- ancestor(a, X).")

2 new api tests cover ancestor and multi-goal usage.
This commit is contained in:
2026-05-08 09:41:02 +00:00
parent 148c3f2068
commit f33a8d69f5
5 changed files with 46 additions and 6 deletions

View File

@@ -1,8 +1,8 @@
{
"lang": "datalog",
"total_passed": 179,
"total_passed": 181,
"total_failed": 0,
"total": 179,
"total": 181,
"suites": [
{"name":"tokenize","passed":26,"failed":0,"total":26},
{"name":"parse","passed":18,"failed":0,"total":18},
@@ -12,8 +12,8 @@
{"name":"semi_naive","passed":8,"failed":0,"total":8},
{"name":"negation","passed":10,"failed":0,"total":10},
{"name":"aggregates","passed":16,"failed":0,"total":16},
{"name":"api","passed":11,"failed":0,"total":11},
{"name":"api","passed":13,"failed":0,"total":13},
{"name":"demo","passed":18,"failed":0,"total":18}
],
"generated": "2026-05-08T09:38:47+00:00"
"generated": "2026-05-08T09:40:51+00:00"
}