https://gcc.gnu.org/g:f2a73defb7bd6705d99075c1fd066d43356c0e73
commit r17-4437-gf2a73defb7bd6705d99075c1fd066d43356c0e73 Author: Xavier Del Campo Romero <[email protected]> Date: Thu Sep 17 23:25:51 2026 +0200 cobol: Accept arbitrarily-sized PIC X for ANY LENGTH Under -dialect mf, when the formal parameter is a PIC X ANY LENGTH, it should accept any kind of PIC X(n) defined by the caller. gcc/cobol/ChangeLog: * parse.y: Accept arbitrarily-sized PIC X for ANY LENGTH. Diff: --- gcc/cobol/parse.y | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/cobol/parse.y b/gcc/cobol/parse.y index 14e11e82c5a7..2766b07f1718 100644 --- a/gcc/cobol/parse.y +++ b/gcc/cobol/parse.y @@ -12991,7 +12991,7 @@ cbl_ffi_arg_t::matches( const cbl_ffi_arg_t& that ) const { return true; } } - else if (actual->attr & any_length_e) + else if (actual->attr & any_length_e || formal->attr & any_length_e) return true; } }
