datalog: built-ins + body arithmetic + order-aware safety (Phase 4, 106/106)
Some checks failed
Test, Build, and Deploy / test-build-deploy (push) Failing after 50s
Some checks failed
Test, Build, and Deploy / test-build-deploy (push) Failing after 50s
New lib/datalog/builtins.sx: (< <= > >= = !=) and (is X expr) with + - * /. dl-eval-arith recursively evaluates nested compounds. Safety analysis now walks body left-to-right tracking the bound set: comparisons require all args bound, is RHS vars must be bound (LHS becomes bound), = special-cases the var/non-var combos. db.sx keeps the simple safety check as a forward-reference fallback; builtins.sx redefines dl-rule-check-safety to the comprehensive version. eval.sx dispatches built-ins through dl-eval-builtin instead of erroring. 19 new tests.
This commit is contained in:
@@ -1,13 +1,14 @@
|
||||
{
|
||||
"lang": "datalog",
|
||||
"total_passed": 87,
|
||||
"total_passed": 106,
|
||||
"total_failed": 0,
|
||||
"total": 87,
|
||||
"total": 106,
|
||||
"suites": [
|
||||
{"name":"tokenize","passed":26,"failed":0,"total":26},
|
||||
{"name":"parse","passed":18,"failed":0,"total":18},
|
||||
{"name":"unify","passed":28,"failed":0,"total":28},
|
||||
{"name":"eval","passed":15,"failed":0,"total":15}
|
||||
{"name":"eval","passed":15,"failed":0,"total":15},
|
||||
{"name":"builtins","passed":19,"failed":0,"total":19}
|
||||
],
|
||||
"generated": "2026-05-07T23:40:51+00:00"
|
||||
"generated": "2026-05-07T23:50:44+00:00"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user