1 ! Test alternate entry points for functions when the result types
2 ! of all entry points don't match
4 integer function f1 (a)
12 complex function f2 (a)
22 function f3 (a) result (r)
29 entry e3 (b) result (s)
32 entry g3 (b) result (c)
35 function f4 (a) result (r)
39 entry e4 (a) result (s)
40 entry g4 (a) result (t)
42 if (a .eq. 0) s = 16 + a
43 if (a .gt. 0) t = 17 + a
49 double precision e1, g4
52 if (f1 (6) .ne. 21) call abort ()
53 if (e1 (7) .ne. 49) call abort ()
54 if (f2 (0) .ne. 45) call abort ()
55 if (.not. e2 (45)) call abort ()
56 if (e2 (46)) call abort ()
57 if (f3 (17) .ne. 32) call abort ()
58 if (.not. e3 (42)) call abort ()
59 if (e3 (41)) call abort ()
60 if (g3 (12) .ne. 23) call abort ()
61 if (.not. f4 (-5)) call abort ()
62 if (e4 (0) .ne. 16) call abort ()
63 if (g4 (2) .ne. 19) call abort ()