http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49112
--- Comment #10 from janus at gcc dot gnu.org 2011-05-30 20:09:18 UTC --- (In reply to comment #6) > > > > string = dt%getFormattedString(0, FMT) > > 1 > > Error: 'getformattedstring' at (1) is not a member of the 'datetime' > > structure > > Here is a reduced test case for this error, which is also a regression: ... probably due to my r163631: http://gcc.gnu.org/viewcvs?view=revision&revision=163631 It can be fixed by this partial revert: =================================================================== --- gcc/fortran/resolve.c (revision 174415) +++ gcc/fortran/resolve.c (working copy) @@ -964,9 +964,6 @@ resolve_structure_cons (gfc_expr *expr, int init) t = SUCCESS; - if (expr->ts.type == BT_DERIVED) - resolve_symbol (expr->ts.u.derived); - cons = gfc_constructor_first (expr->value.constructor); /* A constructor may have references if it is the result of substituting a parameter variable. In this case we just pull out the component we