Skip to content

Seal unification semantics with differential tests against _unify - #114

Open
MesTTo wants to merge 1 commit into
trueagi-io:mainfrom
MesTTo:pr/mork-expr-unify-into
Open

Seal unification semantics with differential tests against _unify#114
MesTTo wants to merge 1 commit into
trueagi-io:mainfrom
MesTTo:pr/mork-expr-unify-into

Conversation

@MesTTo

@MesTTo MesTTo commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

Seals the unification engine's semantics with tests only — no engine code added. Eight behavior tests (first-order MGU materialization from either side, repeated-variable constraints on both sides, indirect occurs cycles, variable-namespace separation, first-order-syntactic-only, symbol shape mismatch) plus a ~900-pair differential against an independent walk/occurs-check oracle over finite terms, all through the existing Expr::_unify entry point. The crate previously had no integration tests for unification.

Earlier revisions of this branch added unify_into/apply_bindings wrappers; those duplicated the existing _unify/apply bodies, so they are gone — the tests now target the engine's own entry point directly. If un-deprecating _unify into a public name is wanted, that is a separate four-line decision.

Eight targeted behavior tests (first-order MGU materialization, nested MGU from
either side, repeated-variable constraints on both sides, indirect occurs
cycles, variable-namespace separation, first-order-syntactic-only, symbol shape
mismatch reporting) plus a ~900-pair differential against a clean walk/occurs
oracle over finite terms, all through the existing engine entry point _unify.
The crate had no integration tests for unification; these pin its contract
without adding or duplicating any engine code.
@MesTTo MesTTo changed the title Add expr unify_into with binding application Seal unification semantics with differential tests against _unify Jul 4, 2026
@MesTTo
MesTTo force-pushed the pr/mork-expr-unify-into branch from 5a03002 to 149c949 Compare July 4, 2026 12:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant