Skip to content

Fix ZONED/PACKED/BINDEC decimal position ToolTip Fixes issue #480#478

Open
bobcozzi wants to merge 5 commits intocodefori:mainfrom
bobcozzi:fix/zoned-packed-bindec-decimals
Open

Fix ZONED/PACKED/BINDEC decimal position ToolTip Fixes issue #480#478
bobcozzi wants to merge 5 commits intocodefori:mainfrom
bobcozzi:fix/zoned-packed-bindec-decimals

Conversation

@bobcozzi
Copy link

@bobcozzi bobcozzi commented Dec 23, 2025

  • ZONED and PACKED now render with :0 when decimals are zero (e.g., ZONED(5:0) instead of ZONED(5:))
  • BINDEC now omits :0 by convention (e.g., BINDEC(9) instead of BINDEC(9:0))
  • BINDEC includes decimal positions when non-zero (e.g., BINDEC(9:3))
  • Set default decimals to '0' instead of empty string in getPrettyType()

Changes

Updated the tooltip (hover text) that shows up for field definitions for Zoned and BinDec variables. Also added similar code to Packed Decimal although the issue was not directly observed for packed, I felt it was good measure to include it there as well.

Checklist

  • have tested my change
  • updated relevant documentation
  • Remove any/all console.logs I added
  • eslint is not complaining
  • have added myself to the contributors' list in the README
  • for feature PRs: PR only includes one feature enhancement.

- ZONED and PACKED now render with :0 when decimals are zero (e.g., ZONED(5:0) instead of ZONED(5:))
- BINDEC now omits :0 by convention (e.g., BINDEC(9) instead of BINDEC(9:0))
- BINDEC includes decimal positions when non-zero (e.g., BINDEC(9:3))
- Set default decimals to '0' instead of empty string in getPrettyType()
@worksofliam worksofliam requested review from chrjorgensen and worksofliam and removed request for chrjorgensen December 25, 2025 13:53
- Remove aggressive fallback logic that could show incorrect subfields
- Rely on findDefinition() for proper scope/qualification awareness
- Keep parent structure context display for correctly-found symbols
- Improve correctness: show nothing instead of something wrong
@bobcozzi
Copy link
Author

bobcozzi commented Jan 12, 2026

Was there anything else I need to change/fix in this PR to get it into the extension?

…ensive tests

- Fixed parseDLine() to correctly parse decimal positions (columns 41-42)
- Updated getPrettyType() to always include decimals in BINDEC output
- Added tests for both free-format and fixed-format BINDEC declarations
- All 290 tests passing
@bobcozzi bobcozzi changed the title Fix ZONED/PACKED/BINDEC decimal position ToolTip Fix ZONED/PACKED/BINDEC decimal position ToolTip Fixes issue #478 Feb 16, 2026
@bobcozzi bobcozzi changed the title Fix ZONED/PACKED/BINDEC decimal position ToolTip Fixes issue #478 Fix ZONED/PACKED/BINDEC decimal position ToolTip Fixes issue #480 Feb 16, 2026
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.

Symbol Database incorrectly stored "B" (BINDEC) Variable Definitions

1 participant