Skip to content

Det: refuse a non-digit in the receiver of ADD / SUBTRACT / MULTIPLY / DIVIDE (Part of #4692) - #4889

Merged
squid-protocol merged 2 commits into
mainfrom
feat/4692-zoned-receiver
Oct 11, 2026
Merged

squid-protocol merged 2 commits into
mainfrom
feat/4692-zoned-receiver

Conversation

@squid-protocol

Copy link
Copy Markdown
Owner

Part of #4692 (the P-position sender, #4685, is not done).

Measured. cobc 3.1.2 (-std=ibm -fsign=EBCDIC, TRUNC STD and BIN, also -O2) does not add in place for a zoned receiver holding spaces, letters, low-values, X'FF', ! or a bad sign byte: cob_add_int reads it through cob_decimal_set_display as it does an operand (ADD 1 TO four spaces: 1601; 12A4: 1375). Across 5 receiver shapes x ADD / SUBTRACT / ROUNDED / ON SIZE ERROR / field operand / MULTIPLY / MOVE / GIVING / COMPUTE the det runtime's old read already agreed with cobc.

IBM. Silent on the digits. ZONEDATA(PFD), the default (and what the estate's evidence records carry), assumes valid zone bits; under NOPFD|MIG an ADD corrects invalid zone bits (APAR PI57769); PI90571 / PH21007 / PH20362 widen NOPFD|MIG to MOVEs, compares and computes but state no digit result. Sources are quoted in register C11.

Change. Policy (IBM reference, oracle the instrument): the port refuses by name, at run time, before it stores, when the receiver of ADD / SUBTRACT / MULTIPLY / DIVIDE holds a non-digit (Cobol.receiverNum; "arithmetic whose receiver is a zoned item holding a non-digit is not modelled ... register C11"). MOVE / GIVING receivers (overwritten) and COMPUTE y = y + 1 (operand rule) are unchanged and measured. C11 updated + rendered. test_det_nondigit_zoned.py extended (cobc-checked expected file, refusal per shape).

Reach (static, heuristic upper bound). 88 receiver statements in the burned estates; 17 in CardDemo (8 programs) can see a non-digit (commarea page counters cleared by MOVE SPACES; CBEXPORT's counter; COTRN02C MOVE TRAN-ID TO WS-TRAN-ID-N after HIGH-VALUES); CBSA 4 / GenApp 23 / others 0 cannot.

Ports. det_port.py check: all 104 ports changed (the shared runtime's Cobol.java, +14 lines, inert for digit-only data); the 33 whose generated code changed were re-proven: 33/33 PROVED. The other 71 changed only in the runtime copy: left for CI's det sweep.

Gates: pr_gates --fast 5/5, --ratchets 7 pass 0 skipped.

🤖 Generated with Claude Code

https://claude.ai/code/session_01AUWeQX7v4QBdErFbghEEEX

squid-protocol and others added 2 commits October 11, 2026 07:33
…/ DIVIDE by name (Part of #4692)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01AUWeQX7v4QBdErFbghEEEX
…E, measured, IBM sources, refused (Part of #4692)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01AUWeQX7v4QBdErFbghEEEX
@squid-protocol squid-protocol added the shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md label Oct 11, 2026
@squid-protocol

Copy link
Copy Markdown
Owner Author

No description provided.

@squid-protocol
squid-protocol marked this pull request as ready for review October 11, 2026 12:17
@squid-protocol
squid-protocol enabled auto-merge (squash) October 11, 2026 12:17
@github-actions

Copy link
Copy Markdown
Contributor

🐦‍⬛ Muninn Security Scan

✅ No security issues found.

🐦‍⬛ Powered by Muninn · Skald Lab

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant