re PR fortran/35770 (implicit character(s) hides type of internal function)

2008-09-13  Daniel Kraft  <d@domob.eu>

	PR fortran/35770
	* primary.c (gfc_match_varspec): Added missing type-spec clearing
	after wrong implicit character typing.

2008-09-13  Daniel Kraft  <d@domob.eu>

	PR fortran/35770
	* gfortran.dg/implicit_13.f90: New test.

From-SVN: r140336
This commit is contained in:
Daniel Kraft 2008-09-13 09:44:36 +02:00 committed by Daniel Kraft
parent f754734f68
commit 858f1fa2a3
4 changed files with 36 additions and 1 deletions

View File

@ -1,3 +1,9 @@
2008-09-13 Daniel Kraft <d@domob.eu>
PR fortran/35770
* primary.c (gfc_match_varspec): Added missing type-spec clearing
after wrong implicit character typing.
2008-09-12 Richard Guenther <rguenther@suse.de>
* trans-intrinsic.c (gfc_conv_intrinsic_transfer): Use

View File

@ -1869,7 +1869,10 @@ check_substring:
case MATCH_NO:
if (unknown)
gfc_clear_ts (&primary->ts);
{
gfc_clear_ts (&primary->ts);
gfc_clear_ts (&sym->ts);
}
break;
case MATCH_ERROR:

View File

@ -1,3 +1,8 @@
2008-09-13 Daniel Kraft <d@domob.eu>
PR fortran/35770
* gfortran.dg/implicit_13.f90: New test.
2008-09-11 Steve Ellcey <sje@cup.hp.com>
* gcc.c-torture/compile/pr11832.c: xfail on ia64-*-*.

View File

@ -0,0 +1,21 @@
! { dg-do compile }
! PR fortran/35770
! Implicit declaration hides type of internal function.
! Contributed by Dick Hendrickson <dick.hendrickson@gmail.com>
IMPLICIT CHARACTER (s)
REAL :: RDA
RDA = S_REAL_SQRT_I(42) ! { dg-bogus "Can't convert" }
CONTAINS
REAL FUNCTION S_REAL_SQRT_I(I) RESULT (R)
IMPLICIT NONE
INTEGER :: I
R = 0.0
END FUNCTION S_REAL_SQRT_I
END