+2005-11-02 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
+
+ * decl.c (gfc_match_entry): Function entries don't need an argument
+ list if there's no RESULT clause.
+
2005-11-01 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
PR fortran/24008
gfc_compile_state state;
match m;
gfc_entry_list *el;
+ locus old_loc;
m = gfc_match_name (name);
if (m != MATCH_YES)
}
else
{
- /* An entry in a function. */
- m = gfc_match_formal_arglist (entry, 0, 0);
+ /* An entry in a function.
+ We need to take special care because writing
+ ENTRY f()
+ as
+ ENTRY f
+ is allowed, whereas
+ ENTRY f() RESULT (r)
+ can't be written as
+ ENTRY f RESULT (r). */
+ old_loc = gfc_current_locus;
+ if (gfc_match_eos () == MATCH_YES)
+ {
+ gfc_current_locus = old_loc;
+ /* Match the empty argument list, and add the interface to
+ the symbol. */
+ m = gfc_match_formal_arglist (entry, 0, 1);
+ }
+ else
+ m = gfc_match_formal_arglist (entry, 0, 0);
+
if (m != MATCH_YES)
return MATCH_ERROR;
+2005-11-02 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
+
+ * gfortran.fortran-torture/execute/entry_9.f90: Revert previous
+ change (r106358).
+
2005-11-01 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
PR fortran/24008