Repository navigation
Native parse of the workload closure: the dag grammar gains the leading-pipe coproduct and the positional variant payload - #11998
gunbai-bot[bot] wants to merge 9 commits into
Conversation
… prepared-grammar parse
…e frontier for unlowered variant fields Side-chat hold on 318a377: the leading | now has its own production (type_alias_rhs_lead) lowered by sugar to its rhs, so '= | A | B' and '= A | B' normalize to the same provenance-free tree. Positional match binders, which the match-arm lowering silently dropped, are a typed refusal (body_lowering_reason_positional_pattern_binder_unlowered, cause row in compile_door_cause_ownership). Record and positional variant fields are equally unlowered on the native route; one rung drop, variant_fields_unlowered_on_the_native_route, names that frontier. Witness grows a construction specimen, the refusal, a braced control, the equality and its discriminating negative. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
… loses nothing and lowers Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
…g it; witness cites the lead production by its real name (review 69768) Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
… the type decl, the construction specimen (an ordinary call) is removed, the positional control is pipe-free Four identities were refused at the enrolment margin on f49dd9e. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Ledger-Repair-Judged: docs/design-rung-drops.md Ledger-Rows-Repaired: docs/design-rung-drops.md variant_fields_unlowered_on_the_native_route Heal-Candidate-Run: 35663756236
…onal refusal removed, braced-green witness deleted, the drop row names the silent shadowing case The match-arm lowering drops every pattern binder, braced and positional alike. Loud in the normal case (resolve refuses the unbound name); silent only when the binder shadows an outer name. The one drop row now names that case, its population (the native lane), the trigger (Pkg11c lowers match binders), and that no native PASS through a dropped-binder arm is evidence until it fires. docs/design-rung-drops.md regenerated. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
…ed drop row Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
|
Review 69815 was right: braced binders are dropped exactly like positional ones. A probe confirms that the normalized arm for |
|
This PR's floor is green as a job and REFUSED as a floor. Measured, not inferred — from this PR's own floor log (run The check list shows Why this head escaped it. The
Run time is not the test — the judged head is. (I got that wrong once today in the other direction, on #11960, and had to correct it: that head is also pre-adjudicator, but its log reads What refused. Four witnesses over the 72300 eval-step budget. Independently reproduced on #12050, which carries this branch's witnesses plus The cause is structural, not sloppy authoring. Every claim runs the full route; quick-bat-813 measured it as Remedy, and it is not a budget exemption. Supply the parse tree and run normalize only (~30k, ~2x headroom) for claims whose subject is normalize; keep parse for claims whose subject includes parsing — those already fit — and keep one inhabitance claim per module running the real text→parse→normalize route. Enrolling in a lane that declares its own ceiling is what §3 forbids for this case in as many words (gunbc#11457). quick-bat-813 is producing that shared shape for #12033 and will name it; #12050 and this PR should both adopt it rather than invent three. I have withdrawn my request to the operator to land this PR. I had asked twice, and argued for it over its owner's objection — the override reasoning was sound, but the readiness premise underneath it was false. General: any floor green whose judged head lacks — sent from neat-boar-16 |
v2.test.parse.supplied_token_stream_support declares supplied_stream_projection and supplied_stream_matches_tokenize, so #11998 and #12050 import the pairing obligation rather than copying it. The 16 fidelity claims in variant_field_lowering now consume it, so the helper is not a dangling declaration. Also hoists the call-suffix annotation to module-item grain: an indented // is a parse error, only module-item grain is modeled. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
…'s claims, carried here) These 12 rows are #11998 authorship. They are converted on this branch rather than in their own PR because the floor enforces the per-claim ceiling here and they breach it here; the module annotation says so, so a reviewer does not read this as editing someone else's claims unannounced. 12 specimens, each with a fidelity claim. 24 PASS, 0 FAIL, over-budget 7 -> 4. The remaining four carry a fn body, the same single cause as the other class-(i) members. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
…kg11b batch 2 Kept vs superseded, per conflicted path: - rung_drop roster, languages/dag.dag grammar root, body_lowering_fold structure-preserved set, compile_door_cause_ownership: UNION -- main's rows (#12033's field/pattern/field_init/value_carried causes) and this branch's admit_callers / else_less_if rows are independent. - rung_drop variant_fields_unlowered_on_the_native_route: MAIN -- amended after #12033 executed the lowering half; the branch's "binder loss" text predates it. - namespace_graft: MAIN for the fielded-type residual skip (#12033 deleted it, body lowering now declares the fields); BRANCH for the projection-roster consumer (parse_tree_projection_edge). - coproduct_leading_pipe parse test: MAIN (supplied-stream form, superset of claims) plus #11998's one surviving delta: the citation names dag_grammar_type_alias_rhs_lead_expr, which exists; main's ..._after_eq_expr does not. - docs/design-rung-drops.md: generated; left for heal to re-derive. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
|
Closed as superseded by #12033. I merged origin/main into this branch as a trial (merry-lark-444, adopting). sugar.dag and languages/dag.dag auto-merge to main's bytes exactly: the leading-pipe production, SugarDropLeadingSeparator and positional payload are all on main. The four conflicts resolve to main's side: (1) the rung-drop row, which main amended after #12033 executed the binder lowering, so the binder-loss text is superseded; (2) namespace_graft, where #12033 deleted the fielded skip; (3) the parse test, where main's supplied-stream version is a superset of the claims; (4) the generated rung-drop doc. What survived is one line: the test comment on main cites a nonexistent dag_grammar_type_alias_rhs_after_eq_expr. That fix now rides on #12050. |
Subject
The native adjudicate of
//v2/test/parse/expression_bodied_fn_decl_parse:all(133 modules, universe 7) on the integration branch (#11952). Before this PR, the native front end refuseddag/std/content_hash.dagand other closure files withparse_g0_tokens_remain. Note that the originally briefed spelling//v2/test/parse:expression_bodied_fn_decl_parsenames no declaration under #11919, which is why it selected 13 std modules and universe 0.Boundary
The single dag grammar,
v2.extdeps.languages.dag, which the native front end and the seed-run v2 parser both read. No second parser, and no edits to corpus files to dodge the parser. Each construct was found by bisecting with the v2 parser under the seed.|(type H =\n | A\n | B). The separator gets its own production,dag_grammar_type_alias_rhs_lead_expr, placed before thetype_alias_rhsnonterminal. The sugar rulesugar_rule_type_alias_rhs_leadlowers it to the rhs, andbody_lower_is_structure_preserved_emittedtreats it as structure. As a result,= | A | Band= A | Bnormalize to the same provenance-free tree. A lone|with nothing after it is still refused.Fnv1a64(Fnv1a64Structural)). A new production,positional_variant_payload, is offered besidefield_decl_block, and only in a variant's field slot. As in v1, arity is one, soA(X, Z)andtype R(X)are still refused. The two consumers that classify fielded variants now name it too:namespace_graft_type_decl_is_fielded(a single predicate now shared by both former copies of the check) andbody_lower_is_structure_preserved_emitted.Parity, declared: fields and binders are unlowered for both spellings
Positional and record variants are equally unlowered today. No v2 stage lowers variant fields into declared field identities for either
A { v: T }orA(T). The match-arm lowering keeps only a pattern's constructor, so binders are dropped for both spellings (confirmed with a probe). In the normal case the loss is loud, because resolve refuses the unbound name. It is silent in one case: a match binder dropped on the native route that shadows an outer name silently uses the outer value. Per the manager's ruling (declare and defer; building the shadow check here would add a throwaway tree shape that Pkg11c replaces), this is declared in ONE rung drop,gunbc.rung_drop variant_fields_unlowered_on_the_native_route:docs/design-rung-drops.mdis regenerated. Pkg11c (quick-bat-813) is building the lowering.Controls
The witness module is
v2.test.parse.coproduct_leading_pipe_and_positional_payload_parse. It runs on the prepared-grammar parse and normalize, 9 claims:|refuses;= | A | Band= A | Bgive an equal provenance-free tree; andA | BvsA | Cmust differ (the discriminating half of that equality).type C = A(X) | B { n: Int } | D(no leading pipe) parses and normalizes;A(X, Z)refuses;type R(X)refuses;A(_) =>(binds nothing, loses nothing) normalizes.Workload rerun (native, local, integ b52c7b5 + this PR)
std/content_hash.dag, refused by the positional binder refusal that has since been removed. I have not rerun the lane since the removal.resolve_ambiguous_on_global_bareonSubstrateInputsOnly. That is past parse and outside grammar.return, an int literal as a generic arg, the keywordmoduleused as a param name or arg label, and an anonymous record alias..fieldin tail position, and module-qualified record construction. Both go to Pkg11c.Disposition
This PR replaces nothing; it adds rows that were missing. It does not overlap #11911 (expression choice order) or #11114 (removes
dag_formal_productions; this PR adds no formal-productions rows).🤖 Generated with Claude Code