Commit c5b9117e by Tobias Burnus Committed by Tobias Burnus

re PR fortran/33188 (Fortran 2003: Type declarations without componends)

2007-08-26  Tobias Burnus  <burnus@net-b.de>

	PR fortran/33188
	* parse.c (parse_derived): Support empty derived type
	definitions for Fortran 2003.

2007-08-26  Tobias Burnus  <burnus@net-b.de>

	PR fortran/33188
	* gfortran.dg/used_types_18.f90: New.

From-SVN: r127808
parent b0d6c7d8
2007-08-26 Tobias Burnus <burnus@net-b.de>
PR fortran/33188
* parse.c (parse_derived): Support empty derived type
definitions for Fortran 2003.
2007-08-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* trans-openmp.c (gfc_omp_privatize_by_reference): Constify.
......
......@@ -1544,11 +1544,11 @@ parse_derived (void)
case ST_END_TYPE:
compiling_type = 0;
if (!seen_component)
{
gfc_error ("Derived type definition at %C has no components");
error_flag = 1;
}
if (!seen_component
&& (gfc_notify_std (GFC_STD_F2003, "Fortran 2003: Derived type "
"definition at %C without components")
== FAILURE))
error_flag = 1;
accept_statement (ST_END_TYPE);
break;
......
2007-08-26 Tobias Burnus <burnus@net-b.de>
PR fortran/33188
* gfortran.dg/used_types_18.f90: New.
2007-08-25 Jakub Jelinek <jakub@redhat.com>
* gcc.dg/array-init-2.c: New test.
! { dg do-compile }
! { dg-options "-std=f2003" }
!
! Fortran 2003 allowes TYPE without components
! The error message for -std=f95 is tested in
! gfortran.dg/access_spec_2.f90
!
! PR fortran/33188
!
type t
end type
end
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment