Skip to content

NFR: route 8 atom-or-not wildcards through node_atom_identity_optional - #12669

Closed
gunbai-bot[bot] wants to merge 3 commits into
mainfrom
session/zesty-owl-698-nfr-undetermined
Closed

gunbai-bot[bot] wants to merge 3 commits into
mainfrom
session/zesty-owl-698-nfr-undetermined

Conversation

@gunbai-bot

@gunbai-bot gunbai-bot Bot commented Sep 29, 2026 •

Copy link
Copy Markdown
Contributor

Burn-down on main for the typed non-fold-residue census behind #12610 (plan ruled by neat-boar-16 via silent-koi-310).

The census reported 10 undetermined sites. Each has a wildcard whose scrutinee has no resolved inferred type: match x.kind, with x bound by Present { value: x } out of list_at_optional. The v1 checker doesn't carry the generic payload type into that pattern binder. Each tests for an Atom, and its wildcard answers everything else. v2.std.grammar node_atom_identity_optional is exactly that projection. So 8 of them, plus pattern_head_identity_optional's outer match (same shape), become total matches over Optional. Present { value: id } takes the Atom arm and Absent takes the wildcard's body verbatim. No arm is cloned and behavior is unchanged.

  • v2.extdeps.runtimes.v2_evaluator v2_eval_transform_is_int_add
  • v2.lens.undecidable_verdict_collapse pattern_head_identity_optional (inner + outer)
  • v2.lens.vacuity vacuity_transform_operator_symbol_optional
  • v2.workflow.bash_command_fold_serialize: bash_fold_built_stmt_production_binding, _assign_node, _exit_node, _with_redir_node, _word_node

The two target_model sites test for Conj. They are enumerated per the delegation ruling. In arrow_domain_binder_names every non-Conj arm answers Empty. In produced_decl_function_type_domain_edges every non-Conj arm delegates to the new produced_decl_single_domain_edge. All 10 undetermined sites are gone; none keeps a row.

Green under both scans: none of these sites is on the old parameter-keyed roster, and the wildcards are gone. The floor strictly prepares every touched module, so this PR's floor run type-checks all four.

🤖 Generated with Claude Code

The typed non-fold-residue census (#12610) reported ten sites whose wildcard
scrutinee has no resolved inferred type. Each is `match x.kind` with x bound by
`Present { value: x }` from list_at_optional; the arm tests for an Atom and the
wildcard answers everything else. v2.std.grammar node_atom_identity_optional is
exactly that projection, so eight of them (plus pattern_head_identity_optional's
outer match, the same shape) become total matches over Optional: the wildcard and
the undetermined scrutinee both disappear, with no arm cloned and no behavior
change (Present <-> the Atom arm, Absent <-> the wildcard).

The two remaining (target_model arrow_domain_binder_names and
produced_decl_function_type_domain_edges) test for Conj, which has no projection;
they keep their wildcards with their own rows in the joint landing on #12610.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
gunbai-bot Bot pushed a commit that referenced this pull request Sep 29, 2026
…optional; drop pattern_head_identity_optional (owned by #12669)

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…uling)

arrow_domain_binder_names: every non-Conj NodeKind arm answers Empty (one token).
produced_decl_function_type_domain_edges: every non-Conj arm delegates to
produced_decl_single_domain_edge, which holds the one positional-edge body.
Exhaustive, no copied body; all ten undetermined census sites are now gone.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@gunbai-bot

gunbai-bot Bot commented Sep 29, 2026

Copy link
Copy Markdown
Contributor Author

On the two points the review could not check: node_atom_identity_optional is declared in v2.std.grammar (it answers Present { value: id } for TypeNode { connective: Atom { identity: id } } and Absent otherwise). The target_model arm lists cover v2.std.node NodeKind (TypeNode | ComputationNode) and every Connective (Atom, Conj, Disj, Arrow, Cardinality, Instantiation). The floor run on this PR strictly prepares the touched modules and is the compile check. — sent from zesty-owl-698

@briansrls briansrls left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

APPROVE at 39349db. The Optional projection replacements preserve the Atom/non-Atom split, and the two NodeKind/Connective sites exhaust the closed variants while delegating the former wildcard body once. Current checks, including the strict floor, are green.

…-nfr-undetermined

# Conflicts:
#	src/v2/std/compilers/target_model.dag
@gunbai-bot
gunbai-bot Bot added this pull request to the merge queue Oct 1, 2026
@gunbai-bot

gunbai-bot Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor Author

Consolidated into integration PR #12951 at the operator's request; this branch is merged there unchanged in its own merge commit. Closing here; the branch is kept. — sent from deep-ferret-305

@gunbai-bot gunbai-bot Bot closed this Oct 1, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to a manual request Oct 1, 2026
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