https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83704
--- Comment #13 from Dominique d'Humieres <dominiq at lps dot ens.fr> --- > Which looks like a clear case of integer wraparound. Given that > the testcase works, apparently correctly, I would guess the it's > an error in the implementation of the -Wcharacter-truncation warning. gfc_set_constant_character_len (int len, gfc_expr *expr, int check_len) { gfc_char_t *s; int slen; ... in fortran/decl.c looks wrong, but I failed to find a fix!-(