[Bug fortran/47023] [4.6/4.7 regression] C_Sizeof: Rejects valid code

burnus at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Thu Sep 29 13:12:00 GMT 2011


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47023

--- Comment #6 from Tobias Burnus <burnus at gcc dot gnu.org> 2011-09-29 13:01:49 UTC ---
Seemingly caused by the patch for PR 44649:

2010-07-08  Janus Weil  <janus@gcc.gnu.org>
    PR fortran/44649
    * check.c (gfc_check_c_sizeof,gfc_check_storage_size): New functions.

The problem seems to be the call:
  +  if (verify_c_interop (&arg->ts) != SUCCESS)

The function checks:
  if (ts->type == BT_DERIVED && ts->u.derived != NULL)
    return (ts->u.derived->ts.is_c_interop || ts->u.derived->attr.is_bind_c)
           ? SUCCESS : FAILURE;
  else if (ts->is_c_interop != 1)
    return FAILURE;



More information about the Gcc-bugs mailing list