Repository navigation
COMMAREA basis: a program's concrete declaration outranks a disagreeing caller record (#3688) - #3702
Merged
Merged
Conversation
…ng caller record (#3688) A resolved caller's record used to outrank the program's own LINKAGE DFHCOMMAREA unconditionally. GENAPP's five lg*vs01 were built from a caller record of UNKNOWN width instead of their declared 32,500 bytes, and CBSA's BNK1UAC / UPDACC silently took a caller layout of another size. A CONCRETE own DFHCOMMAREA (fixed length, known width, 2+ elementary fields) now wins when the best caller record is of unknown or variable width, or disagrees in length or field shape. Each caller record becomes an alternative carrying its mismatches. A caller record that matches, or a finer view of an opaque declaration, stands as before. A caller that keeps some of the declared fields as one PIC X block (CardDemo COPAUS1C's 200-byte authorization record) is a COARSER VIEW: compatible, the declaration's detail is used, and nothing is flagged. Java: - the controller and the calling site get a TODO naming both layouts, or the unknown width; - the call-site check now judges by layout, not name (two DFHCOMMAREAs can differ); - the migration worklist files these as conflict / fact-gap items. Effect: - 8 programs change basis; 39/39 compiles pass (3 corpora x 13 configs); - worklist: CBSA +3 conflicts, GENAPP +5 fact-gaps; - snapshots and ledger unchanged; field_testing D025. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_017ZsVaAkb86P5r5JXDC2Y9g
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_017ZsVaAkb86P5r5JXDC2Y9g
Contributor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #3688.
The decision
A CICS program's COMMAREA can be described in two places: by each caller (the record it passes) and by the program itself (its LINKAGE
DFHCOMMAREA). The engine always preferred the caller's. That's right for CardDemo, whose programs declare an opaque byte run (PIC X OCCURS … DEPENDING ON EIBCALEN) and unpack it by hand. It's wrong when the program declares a real layout the callers disagree with.Agreed rule: the program's own concrete declaration wins over a caller that disagrees, and every disagreement is flagged for a person instead of being settled silently.
PIC Xblock)A concrete declaration has a fixed length, a known width and 2 or more elementary fields.
What it changes on the reference estates
lgacvs01 / lgapvs01 / lgdpvs01 / lgucvs01 / lgupvs01: the generated Java used to readCOMMAREA: DFHCOMMAREA (lgacdb01.cbl, None bytes). The DTO was built from a caller record whose size the engine couldn't determine. Each program now uses its own declared 32,500-byte layout, and the callers' unknown width is a fact-gap item.BNK1UAC(declares 103 bytes, hands itself a 99-byteWS-COMM-AREA) andUPDACC(declares 99, receives BNK1UAC's 103): genuine clashes in the sample application. Each now uses its own layout, and both clashes are conflict items. The call site says so too:this site passes DFHCOMMAREA (103 bytes); UPDACC declares DFHCOMMAREA (… 99 bytes).COPAUS2C: its caller passes the 200-byte authorization record as onePIC X(200)where COPAUS2C declares it field by field. That's a coarser view, so the detailed declaration is used and nothing is flagged.Migration worklist: CBSA +3 conflicts, GENAPP +5 fact-gaps, CardDemo unchanged.
Changes
GalaxyIR._declared_over_callersand_coarser_view(engine, IR reader only, so no rescan is needed).commarea_alternative_todossays how each caller disagrees.DFHCOMMAREAcould never mismatch.field_testing.json: D025.Evidence
ir_join_diff: onlyprogram_interfaceschanges: CBSA 2, GENAPP 5, CardDemo 1. zECS, zopeneditor and DSF are unchanged.--javais all PASS. The refraction snapshots and the ground-truth ledger are unchanged.test_commarea_basis.pycovers each row of the table above in a real scan, plus the Java and worklist output.🤖 Generated with Claude Code
https://claude.ai/code/session_017ZsVaAkb86P5r5JXDC2Y9g