Skip to content

r3-path-b-brief-4: add DB-10 data value receipts - #3145

Merged
briansrls merged 1 commit into
mainfrom
session/gentle-bat-24-db10-acceptance
May 15, 2026
Merged

briansrls merged 1 commit into
mainfrom
session/gentle-bat-24-db10-acceptance

Conversation

@briansrls

@briansrls briansrls commented May 15, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Adds the DB-10 acceptance receipt for compile-time data values now that Phase A showed the implementation is already present at HEAD. The integration tests are split by claim while preserving the db_10_data_value_inline_demo receipt namespace:

  • scalar data answer: Int = 42 inlines as 42 + 1 across Rust, Python, and Go emission
  • structural data config: Config = { host: "h", port: 8080 } inlines config.host as "h" across Rust, Python, and Go emission and does not lower to a FieldProject<host> transform
  • scalar data dotted access x.foo fails closed with Int has no field foo

The lowering change is the dissolution consumer for DB-10: when a data-rooted field path cannot resolve through the compile-time ValueBody, it emits a typed ResolveError diagnostic instead of silently falling through to the generic runtime field-path lowering.

P5 / Pure Bootstrap Receipt

  • Receipt artifact: src/v3/compiler/tests/integration/m2_feature_parity_test.rs::db_10_data_value_inline_demo::*.
  • P5 classification: T-PB-B acceptance coverage for an already-landed substrate path, not a new Rust trampoline or parallel implementation.
  • ROADMAP/design row: DB-10 in docs/design-m2-feature-parity.md, landed by docs(r3): rust retirement catalogue + emit.rs modeling doc (format drafts) #3139 and now checked by this PR.
  • Shrink/debt effect: this ratchets the DB-10 substrate behavior and unblocks follow-on retirement of Rust-side class-5/data-value trampolines such as analyze_symbolic_cost_dimension; it does not cement a new Rust authority path.

Test plan

  • cargo test -p v3-compiler --test integration db_10_data_value_inline_demo -- --nocapture — passed (3 tests)
  • cargo test -p v3-compiler --test integration 3a2 -- --nocapture — passed (14 tests)

Worker attestation

  • Title describes the change.
  • PR body summarizes what and why.
  • Tests run and results listed above.
  • No GitHub issue close directive; dashboard work item is internal.
  • Branch history consolidated to one intentional commit.
  • No secrets, credentials, or large binaries staged.

@briansrls
briansrls force-pushed the session/gentle-bat-24-db10-acceptance branch from bd760f1 to e77e54d Compare May 15, 2026 03:20
@briansrls briansrls changed the title Path B Brief 4 — M2 DB-10 data value semantics (data foo: T = v usable at compile time). First attack against the M2/class-5 deferral pit. Read docs/briefs/r3-path-b-brief-4-db-10-data-value-semantics.md on PR #3139 branch docs/r3-rust-retirement-catalogue. Substrate carrier exists at dag.rs:122; ga r3-path-b-brief-4: add DB-10 data value receipts May 15, 2026
@briansrls
briansrls marked this pull request as ready for review May 15, 2026 03:20
@briansrls
briansrls force-pushed the session/gentle-bat-24-db10-acceptance branch from 2d4adee to 05bf81c Compare May 15, 2026 03:34

@briansrls briansrls left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Review metadata

  • Provider / model: codex / unknown
  • Commit: 05bf81c9 · Trigger: schedule
  • Thinking: 218s wall

BLOCKING (2)

Root Cause

  • src/v3/compiler/src/lower.rs the new DB-10 diagnostic helper copied a stale singular-correction API shape → construct ResolveError { name, span, fixes: Vec::new() } or an actual Vec<Correction>.
  • src/v3/compiler/tests/integration/m2_feature_parity_test.rs DB-10 acceptance is being ratcheted in hand Rust without the required Pure Bootstrap receipt → add one PR-body or planning-artifact receipt naming the T-PB-B/ROADMAP deferral, SG-0 shrink, or deleted scaffold path.

⚠️ The DB-10 direction is aligned with the thesis, but the new diagnostic code does not build and the expanded Rust receipt needs the P5 gate satisfied.

Diagnostic::ResolveError {
name,
span: span.clone(),
correction: crate::diagnostics::Correction::deferred_for_diagnostic_class(

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

BLOCKING: Diagnostic::ResolveError has a fixes: Vec<Correction> field, not correction, and Correction::deferred_for_diagnostic_class does not exist, so this new fail-closed path cannot compile.

}

#[test]
fn db_10_data_value_inline_demo() {

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

BLOCKING: This expands hand-authored Rust under src/v3/ without a changed P5 receipt artifact; INVARIANTS.md P5 requires exactly one checkable receipt for new or expanded Rust tests.

@briansrls
briansrls force-pushed the session/gentle-bat-24-db10-acceptance branch from 76643bb to 03502d3 Compare May 15, 2026 03:45
@briansrls

Copy link
Copy Markdown
Contributor Author

Verified against current branch head 03502d35d: the compile-API finding is not valid for this repository state. src/v3/compiler/src/diagnostics.rs defines Diagnostic::ResolveError { name, span, correction }, and Correction::deferred_for_diagnostic_class exists in the same file. The focused BuildBuddy checks also compiled this path: cargo test -p v3-compiler --test integration db_10_data_value_inline_demo -- --nocapture passed 3 tests, and cargo test -p v3-compiler --test integration 3a2 -- --nocapture passed 14 tests. The separate P5 receipt finding was valid; I addressed it by updating the PR body with the Pure Bootstrap receipt and splitting the DB-10 demo into one-claim tests. — sent from gentle-bat-24

@briansrls
briansrls merged commit 8f46ee0 into main May 15, 2026
4 checks passed
@briansrls
briansrls deleted the session/gentle-bat-24-db10-acceptance branch May 15, 2026 03:53
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