Skip to content

det translator: a hex literal naming a line-end character (X'0A', X'0D') in a MOVE emits a Java string that does not compile #4690

Closed

Description

@squid-protocol

Part of #4270. Found while measuring #4662 (C11). MOVE X'313233 0A' TO R (any hex literal holding X'0A' or X'0D') is emitted as Cobol.move("123\u000a", f, CS): Java translates the unicode escape before lexing, so the string literal is cut open and javac fails (unclosed string literal). Expected: escape such bytes as \n / \r (or \012 octal) in the emitted literal. The oracle compiles and runs them. Reproduce: a one-statement program MOVEing X'0A' to PIC X.

Activity

  1. added
    bug
    legacy-modernization
    priority: low
    on Oct 8, 2026
  2. added
    scope:sweep
    on Oct 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    buglegacy-modernizationpriority: lowscope:sweep

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions