Elamur Groupants⌕
☰

modelcheck-syntax-admission-parsing

The groupant beside tools/modelcheck/src/syntax.rs in the Mova repository: what the code computes, what it never does, how to go back from its outputs, its invariants, cost and checks.

Facts

Implementation material. A Mova code model describes this code at one source revision: partial models, finite checks and their stated scope. It is not a reviewed general exposition, and its labels are shown as written, never raised.

Components

componentlabelwhere
approximantpartialforward
astpartial../syntax.json
costpartialinvariant-and-cost
descriptantpresentdescriptant
invariantpartialinvariant-and-cost
testsfinite native evidencetests

Obernants

The typed relations around the forward model: the behaviour complement (what the code never does), the reverse reconstruction (every input compatible with an output) and specialised views.

idtypelabelwhere
behavior_complementbehavior_complementpartial relational specificationbehavior_complement
reverse_reconstructionreverse_reconstructionpartial relational specificationreverse_reconstruction
admission_precedenceadmission_precedencepartial relational specificationadmission_precedence
sorted_discovery_joinsorted_discovery_joinpartial relational specificationsorted_discovery_join
empty_source_identityempty_source_identitypartial relational specificationempty_source_identity
opaque_external_boundaryopaque_external_boundarypartial relational specificationopaque_external_boundary

Model text

descriptant

Path admission, sorted Git membership, source read and syn parse projection groupant

Epoch 2026-10-31: materialized a scoped view after full-source review. Reject nonnormalized/non-Rust path, canonicalize root, require sorted discovery membership, confine file, read UTF-8, parse with syn, visit and reject invalid spans. Emit exact input path/hash/bytes, parser identity and limitations.

Projection source binds the same UTF-8 bytes passed to parse. Failed admission/parsing produces no Projection. Git discovery includes nonignored untracked files. No external module, cfg evaluation or macro expansion occurs.

Useful prior epochs remain in the parent descriptant. This child uses exact byte anchors and the same whole-source hash: editing unrelated bytes also invalidates its binding. The fragment is a partial structural/behavior model, not a proof. No executable percentage surrogate is supplied: categorical gates have no defined useful loss metric; any future profile must use supported caps 1, 2, 5 or 10 percent with explicit domain and evidence.

catalog

Wave33 historical scope and evidence follow. Current source hashes and refreshed ranges are in manifest.json; wave34 refinements and evidence are at the source root.

Path admission, sorted Git membership, source read and syn parse projection typed models

Subject/revision: source SHA-256 in manifest; scope [888 , 2943). Domain is one completed scoped call on a fixed snapshot with adequate resources, unless narrowed below. Observation includes return/error and declared filesystem effects. Models are source-derived partial relational constraints; complements are inner exclusion hypotheses, converse relations retain compatible-input ambiguity. No universal proof or inverse executor is claimed. Evidence: syntax::tests::discovery_and_exclusive_output_reject_unsupported_paths; syntax::tests::source_symlink_escape_is_rejected; syntax::tests::omitted_attributes_macro_bodies_and_external_modules_preserve_shape. Mutation evidence and limits are recorded in ../wave33-evidence.md.

behavior_complement

Exclude successful projection of ignored/missing/unconfined/non-UTF8/nonparseable source or path with empty/dot/dot-dot slash component.

Oracle: syntax::tests::discovery_and_exclusive_output_reject_unsupported_paths; syntax::tests::source_symlink_escape_is_rejected; syntax::tests::omitted_attributes_macro_bodies_and_external_modules_preserve_shape. Fixed source scope and the stated domain are required; finite checks do not establish untested generality.

reverse_reconstruction

Output fixes path, digest, byte count and selected nodes; it admits all hash-compatible source snapshots and unrelated repository states. Output destination is not part of this API.

Oracle: syntax::tests::discovery_and_exclusive_output_reject_unsupported_paths; syntax::tests::source_symlink_escape_is_rejected; syntax::tests::omitted_attributes_macro_bodies_and_external_modules_preserve_shape. Fixed source scope and the stated domain are required; finite checks do not establish untested generality.

admission_precedence

Normalized path rejection precedes root canonicalization and Git; membership rejection precedes source read. Errors preserve this first-failure order.

Oracle: syntax::tests::discovery_and_exclusive_output_reject_unsupported_paths; syntax::tests::source_symlink_escape_is_rejected; syntax::tests::omitted_attributes_macro_bodies_and_external_modules_preserve_shape. Fixed source scope and the stated domain are required; finite checks do not establish untested generality.

sorted_discovery_join

rust_files emits strict String order; discovered_source returns the same present/absent bit as old linear search. No additional read or filesystem check is introduced.

Oracle: syntax::tests::discovery_and_exclusive_output_reject_unsupported_paths; syntax::tests::source_symlink_escape_is_rejected; syntax::tests::omitted_attributes_macro_bodies_and_external_modules_preserve_shape. Fixed source scope and the stated domain are required; finite checks do not establish untested generality.

empty_source_identity

Empty UTF-8 source yields one File node [0,0) and empty-source digest. A nonempty comments-only file can also yield one node but differs in bytes and hash.

Oracle: syntax::tests::discovery_and_exclusive_output_reject_unsupported_paths; syntax::tests::source_symlink_escape_is_rejected; syntax::tests::omitted_attributes_macro_bodies_and_external_modules_preserve_shape. Fixed source scope and the stated domain are required; finite checks do not establish untested generality.

opaque_external_boundary

mod absent; can project without absent.rs; changing cfg attributes or macro body tokens can preserve parent/category/variant/opaque triples while full digest/ranges differ.

Oracle: syntax::tests::discovery_and_exclusive_output_reject_unsupported_paths; syntax::tests::source_symlink_escape_is_rejected; syntax::tests::omitted_attributes_macro_bodies_and_external_modules_preserve_shape. Fixed source scope and the stated domain are required; finite checks do not establish untested generality.

tests

Native correspondence

Exact named checks: syntax::tests::discovery_and_exclusive_output_reject_unsupported_paths; syntax::tests::source_symlink_escape_is_rejected; syntax::tests::omitted_attributes_macro_bodies_and_external_modules_preserve_shape.

See ../wave33-evidence.md for current repeated profiles, actual production mutants and scope limits. AST generation alone is not behavioral evidence. Each reference test body was read before execution.

forward

Scoped forward model

Path admission, sorted Git membership, source read and syn parse projection

Reject nonnormalized/non-Rust path, canonicalize root, require sorted discovery membership, confine file, read UTF-8, parse with syn, visit and reject invalid spans. Emit exact input path/hash/bytes, parser identity and limitations.

invariant-and-cost

Invariant and cost

Projection source binds the same UTF-8 bytes passed to parse. Failed admission/parsing produces no Projection. Git discovery includes nonignored untracked files. No external module, cfg evaluation or macro expansion occurs.

Git process/sorting O(P log P), membership O(log P) comparisons, source read/hash O(B), plus syn parse and selected traversal. No claim of bounded parser recursion or whole-command speedup.

This page in Markdown → https://md.groupants.elamur.ai/free/en/mova/tools/modelcheck/src/syntax.rs.groupant/admission-parsing.groupant/