MONDAY, JULY 27, 2026
cobol
Accept NUL in COBOL comments.
COBOL front-end now ignores NUL characters within comments.
The GNU COBOL front-end has been updated to tolerate NUL characters within comments. Previously, a NUL character would cause a compilation error, but this change ensures that comments containing NULs are processed without issue.
In Details
Enhances the COBOL lexer by allowing NUL characters within comments, preventing compilation failures. This is achieved by introducing a sanitize_nul function in lexio.cc and lexio.h.
For Context
- NUL
- The null character, represented as '\0' or ASCII value 0. It is often used as a string terminator in C but can appear in other contexts.