Incorrect calculation of record size when a signed numeric field is part of a REDEFINES (AcuCobol)

We are scanning Cobol sources.

The size of a record with a signed numeric field that is part of a REDEFINES is calculated incorrectly when the record is the target of a MOVE statement.

Versions used:
Cobol: AcuCobol version 10.2.1, fixed format
SonarQube: Enterprise Edition Version 9.6.1 (build 59531)

Source code example:

       IDENTIFICATION DIVISION.
       PROGRAM-ID. PP0036.
       WORKING-STORAGE SECTION.
       COPY "C/REC/SOME_RECORD".
      * The content of REC/SOME_RECORD is:

      *01  REC-NAME.
      *    05  RECORD-DATA.
      *        10  RECORD-SIGNED-NUMERIC        PIC S9(05).
      *    05  RECORD-DATA-REDEF REDEFINES RECORD-DATA.
      *        10  RECORD-ALPHANUMERIC-FIELD    PIC X(06).

       COPY "C/REC/SOME_RECORD" REPLACING ==REC-NAME== BY ==COPY-NAME==.
       PROCEDURE DIVISION.
           MOVE REC-NAME TO COPY-NAME
           GOBACK.

SonarQube complains about this MOVE:

‘Increase the size of “COPY-NAME” (of size 5) or do not “MOVE” “REC-NAME” (of size 6) to it.’

Apparently it forgets about the position that the sign takes up when calculating the target field size.
It only does this wrong when the numeric field is part of an area that is REDEFINED.
(In our production code we had 4 numeric fields, 3 of which were in the redefined portion, and there the size-difference shown was 3).

This kind of error is very toxic, as it undermines the confidence that developers have in SonarQube.
(Remark from one of our dev’s:“It cant even calculate the size of a record properly and consistently”)
So please fix this problem.

Thank you for your feedback.
Ticket created: SONARCOBOL-1662