Repository navigation
det: a binary Db2 host variable takes what its bytes hold, -304 only beyond its width (#4579) - #4580
Merged
Merged
Conversation
…beyond its width (#4579) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_017BVJCCUMdjLJq1TAM3V34V
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_017BVJCCUMdjLJq1TAM3V34V
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 #4579
DetSql checked a numeric Db2 value against the host variable's PICTURE digits, so 2147483647 into S9(9) COMP gave -304. Now
Cobol.storeHostChecked(used by DetSql.into) checks a binary item (COMP / COMP-4 / BINARY / COMP-5) against its 2/4/8-byte range regardless of TRUNC, as ggsql.c num_store does; the program's TRUNC is restored after. TRUNC(STD) still governs COBOL MOVE/arithmetic (C1). Documented as Q1a in oracle_assumptions.md.Evidence: new test (halfword/fullword/doubleword boundaries, +/-, STD and BIN, COMP-5) fails without the fix; det_port run cbsa-updacc-generated, cbsa-updacc, cbsa-inqacc, cbsa-delacc all PROVED (Db2, EQUIVALENCE_E2E); cbsa-updacc-generated baseline line removed (#4577 merged); pr_gates --ratchets pass. Full suite: only test_tool_regex_redos timing flake on files this PR does not touch.
🤖 Generated with Claude Code
https://claude.ai/code/session_017BVJCCUMdjLJq1TAM3V34V