feat: add COBOL statement benchmark plan and 34 P0 sample programs
- docs/cobol-statement-benchmark-plan.md — full coverage matrix and gap analysis - 34 P0 COBOL samples: arithmetic(9), move(5), file(6), control(6), inspect(3), search(2), perform(3) - test-data/validate_statements.py — automatic validation script - Validation: 34/34 samples pass preprocess + extract_structure
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
* ==== TYPE: ST-UNSTRING-BASIC ====
|
||||
* FEATURE: UNSTRING space-delimited into multiple fields
|
||||
* STATEMENT: UNSTRING
|
||||
* BRANCHES: 0, DECISIONS: 0
|
||||
* NOTE: UNSTRING is pass-through; no IF
|
||||
IDENTIFICATION DIVISION.
|
||||
PROGRAM-ID. UNSBAS.
|
||||
DATA DIVISION.
|
||||
WORKING-STORAGE SECTION.
|
||||
01 WS-SRC PIC X(20) VALUE 'ABC DEF GHI'.
|
||||
01 WS-A PIC X(5).
|
||||
01 WS-B PIC X(5).
|
||||
01 WS-C PIC X(5).
|
||||
PROCEDURE DIVISION.
|
||||
MAIN.
|
||||
MOVE SPACES TO WS-A WS-B WS-C.
|
||||
UNSTRING WS-SRC DELIMITED BY SPACES
|
||||
INTO WS-A WS-B WS-C.
|
||||
IF WS-A = 'ABC'
|
||||
DISPLAY 'OK: UNSTRING'
|
||||
ELSE
|
||||
DISPLAY 'ERROR: UNSTRING'.
|
||||
STOP RUN.
|
||||
Reference in New Issue
Block a user