annotate gcc/testsuite/gfortran.dg/constructor_4.f90 @ 158:494b0b89df80 default tip

...
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Mon, 25 May 2020 18:13:55 +0900
parents 04ced10e8804
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
111
kono
parents:
diff changeset
1 ! { dg-do compile }
kono
parents:
diff changeset
2 ! { dg-options "-std=f95" }
kono
parents:
diff changeset
3 !
kono
parents:
diff changeset
4 ! PR fortran/39427
kono
parents:
diff changeset
5 !
kono
parents:
diff changeset
6 ! Check constructor functionality.
kono
parents:
diff changeset
7 !
kono
parents:
diff changeset
8 !
kono
parents:
diff changeset
9 module m
kono
parents:
diff changeset
10 type t ! { dg-error "the same name as derived type" }
kono
parents:
diff changeset
11 integer :: x
kono
parents:
diff changeset
12 end type t
kono
parents:
diff changeset
13 interface t
kono
parents:
diff changeset
14 module procedure f
kono
parents:
diff changeset
15 end interface t
kono
parents:
diff changeset
16 contains
kono
parents:
diff changeset
17 function f() ! { dg-error "the same name as derived type" }
kono
parents:
diff changeset
18 type(t) :: f
kono
parents:
diff changeset
19 end function
kono
parents:
diff changeset
20 end module
kono
parents:
diff changeset
21
kono
parents:
diff changeset
22 module m2
kono
parents:
diff changeset
23 interface t2
kono
parents:
diff changeset
24 module procedure f2
kono
parents:
diff changeset
25 end interface t2
kono
parents:
diff changeset
26 type t2 ! { dg-error "the same name as derived type" }
kono
parents:
diff changeset
27 integer :: x2
kono
parents:
diff changeset
28 end type t2
kono
parents:
diff changeset
29 contains
kono
parents:
diff changeset
30 function f2() ! { dg-error "the same name as derived type" }
kono
parents:
diff changeset
31 type(t2) :: f2
kono
parents:
diff changeset
32 end function
kono
parents:
diff changeset
33 end module