PR fortran/43832
* io.c (gfc_match_open): Remove branch to syntax error. Add call to
gfc_error with new error message.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158684
138bc75d-0d04-0410-961f-
82ee72b054a4
+2010-04-24 Jerry DeLisle <jvdelisle@gcc.gnu.org>
+
+ PR fortran/43832
+ * io.c (gfc_match_open): Remove branch to syntax error. Add call to
+ gfc_error with new error message.
+
2010-04-24 Paul Thomas <pault@gcc.gnu.org>
PR fortran/43841
if (m == MATCH_NO)
{
m = gfc_match_expr (&open->unit);
- if (m == MATCH_NO)
- goto syntax;
if (m == MATCH_ERROR)
goto cleanup;
}
goto cleanup;
}
}
+ else if (!open->unit)
+ {
+ gfc_error ("OPEN statement at %C must have UNIT or NEWUNIT specified");
+ goto cleanup;
+ }
/* Checks on the ACCESS specifier. */
if (open->access && open->access->expr_type == EXPR_CONSTANT)