+2018-02-07 Steven G. Kargl <kargl@gcc.gnu.org>
+
+ PR fortran/82049
+ * match.c (gfc_match_type_spec): If the charlen is non-NULL, then
+ try to resolve it. While here return early if possible.
+
2018-02-04 Paul Thomas <pault@gcc.gnu.org>
PR fortran/84115
{
match m;
locus old_locus;
- char name[GFC_MAX_SYMBOL_LEN + 1];
+ char c, name[GFC_MAX_SYMBOL_LEN + 1];
gfc_clear_ts (ts);
gfc_gobble_whitespace ();
old_locus = gfc_current_locus;
+
+ /* If c isn't [a-z], then return immediately. */
+ c = gfc_peek_ascii_char ();
+ if (!ISALPHA(c))
+ return MATCH_NO;
+
type_param_spec_list = NULL;
if (match_derived_type_spec (ts) == MATCH_YES)
ts->type = BT_CHARACTER;
m = gfc_match_char_spec (ts);
+ if (ts->u.cl && ts->u.cl->length)
+ gfc_resolve_expr (ts->u.cl->length);
if (m == MATCH_NO)
m = MATCH_YES;
+2018-02-07 Steven G. Kargl <kargl@gcc.gnu.org>
+
+ PR fortran/82049
+ * gfortran.dg/assumed_charlen_parameter.f90: New test.
+
2018-02-07 David Malcolm <dmalcolm@redhat.com>
PR c++/81610
--- /dev/null
+! { dg-do compile }
+! PR fortran/82049
+! Original code contributed by John Harper <john dot harper at vuw dot ac dot nz>
+program ice ! f2003
+ implicit none
+ character(*), parameter:: a = 'ice', b = '*'
+ character(*), parameter:: c(2) = [character(len(a)) :: a, b]
+ print "(2A4)",adjustr(c)
+end program ice