You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Generated REST controller does not compile when a file is ASSIGNed to a literal path ("./TEST-FILE" -> @RequestBody ./testFileDTO) #3957
Found while preparing the opensourcecobol4j fresh estate (#3806, epic #3803): pre-trial generation, no porting. The generated jp-compat project does not compile (mvn -o compile, JDK 17). All 8 of its "Allow no file open (I-O / EXTEND ...)" programs fail.
Defect
generate_rest_controller (gitgalaxy/tools/cobol_to_java/cobol_to_java_api_contract_forge.py) builds Java names from a program's file inputs by only splitting on -. If a program SELECTs a file ASSIGNed to a literal path, the path goes straight into the Java source, e.g. ASSIGN "./TEST-FILE". PC dialects (GnuCOBOL, opensourcecobol4j, Micro Focus) use that form, and so does any ASSIGN to "data/in.dat". The result is:
Expected: a valid Java identifier (e.g. TestFileDTO testFileData). The best source is the SELECT's file name (TEST-FILE), not the ASSIGN text. Otherwise the ASSIGN text should be reduced to identifier characters, and the generated project should compile.
Activity
Fix #3998: no-scan lineage reads SELECT with the engine's reader (#3999)