PR fortran/50524
* resolve.c (resolve_ref): Check return value of resolve_substring().
2011-10-15 Steven G. Kargl <kargl@gcc.gcu.org>
PR fortran/50524
* gfortran.dg/substring_integer_index.f90: New test.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@180262
138bc75d-0d04-0410-961f-
82ee72b054a4
2011-10-30 Steven G. Kargl <kargl@gcc.gnu.org>
+ PR fortran/50524
+ * resolve.c (resolve_ref): Check return value of resolve_substring().
+
+2011-10-30 Steven G. Kargl <kargl@gcc.gnu.org>
+
* io.c (match_dt_format): Match a user-defined operator or a kind
type prefixed string.
break;
case REF_SUBSTRING:
- resolve_substring (ref);
+ if (resolve_substring (ref) == FAILURE)
+ return FAILURE;
break;
}
2011-10-20 Steven G. Kargl <kargl@gcc.gnu.org>
+ PR fortran/50524
+ * gfortran.dg/substring_integer_index.f90: New test.
+
+2011-10-20 Steven G. Kargl <kargl@gcc.gnu.org>
+
* gfortran.dg/format_string.f: New test.
--- /dev/null
+! { dg-do compile }
+! PR fortran/50524
+!
+program foo
+ print *, 'abc'(2.e0:3) ! { dg-error "must be of type INTEGER" }
+ print *,'qwe'(1:1e0) ! { dg-error "must be of type INTEGER" }
+end program foo
+