Landing: 666e349a989a

Project / Subsystem

gcc / cobol

Date

2026-06-05

Author

Robert Dubner

Commit

666e349a989ae51e05463317019efa6b20c7c3b1

Source

github

Perf win

No

Breaking

No

All attributes

project
gcc
subsystem
cobol
patch_id
commit_hash
666e349a989ae51e05463317019efa6b20c7c3b1
source_type
github
headline
GCOBOL displays COMP-1/-2 in IBM format when dialect is set
tldr
GCOBOL now correctly displays COMP-1 and COMP-2 floating-point variables using IBM's specified format when the `-dialect ibm` option is active.
author
Robert Dubner
outcome
committed
performance_win
false
breaking_change
false
series_id
series_parts
[]
tags
  • cobol
  • ibm
  • compatibility
  • floating-point
discussion_id_link
bugzilla_pr
date
2026-06-05T00:00:00.000Z

This commit modifies GCOBOL to adopt IBM’s specified display format for COMP-1 and COMP-2 floating-point variables when the compiler is invoked with the -dialect ibm option. Previously, GCOBOL used its own idiosyncratic display, but now it adheres to the COBOL specification where COMP-1 displays as if it had a picture clause of -.9(8)E-99, and COMP-2 as -.9(17)E-99. This ensures greater compatibility and predictability for COBOL developers targeting IBM systems.