[Bug fortran/30882] size with initialization expression value for dim= is rejected
--- Comment #4 from burnus at gcc dot gnu dot org 2007-03-03 10:43 --- Subject: Bug 30882 Author: burnus Date: Sat Mar 3 10:43:25 2007 New Revision: 122503 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=122503 Log: 2007-03-03 Paul Thomas <[EMAIL PROTECTED]> PR fortran/30882 * check.c (dim_rank_check): The shape of subsections of assumed-size arrays is known. 2007-03-03 Paul Thomas <[EMAIL PROTECTED]> PR fortran/30882 * gfortran.dg/size_dim.f90: New test. -- Diese und die folgenden Zeilen werden ignoriert -- Mgcc/testsuite/ChangeLog Agcc/testsuite/gfortran.dg/size_dim.f90 Mgcc/fortran/ChangeLog Mgcc/fortran/check.c Added: trunk/gcc/testsuite/gfortran.dg/size_dim.f90 Modified: trunk/gcc/fortran/ChangeLog trunk/gcc/fortran/check.c trunk/gcc/testsuite/ChangeLog -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30882
[Bug fortran/30882] size with initialization expression value for dim= is rejected
--- Comment #3 from patchapp at dberlin dot org 2007-03-03 03:01 --- Subject: Bug number PR30882 A patch for this bug has been added to the patch tracker. The mailing list url for the patch is http://gcc.gnu.org/ml/gcc-patches/2007-03/msg00111.html -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30882
[Bug fortran/30882] size with initialization expression value for dim= is rejected
--- Comment #2 from pault at gcc dot gnu dot org 2007-02-22 09:30 --- (In reply to comment #1) This fixes it: Index: gcc/fortran/check.c === *** gcc/fortran/check.c (revision 122101) --- gcc/fortran/check.c (working copy) *** dim_rank_check (gfc_expr *dim, gfc_expr *** 337,343 ar = gfc_find_array_ref (array); rank = array->rank; ! if (ar->as->type == AS_ASSUMED_SIZE && !allow_assumed) rank--; if (mpz_cmp_ui (dim->value.integer, 1) < 0 --- 337,346 ar = gfc_find_array_ref (array); rank = array->rank; ! if (ar->as->type == AS_ASSUMED_SIZE ! && !allow_assumed ! && ar->type != AR_ELEMENT ! && ar->type != AR_SECTION) rank--; if (mpz_cmp_ui (dim->value.integer, 1) < 0 As with other recent PRs, I cannot do anything with it for a bit - feel free to see it to completion. Paul -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30882
[Bug fortran/30882] size with initialization expression value for dim= is rejected
--- Comment #1 from burnus at gcc dot gnu dot org 2007-02-20 14:04 --- IF(SIZE(a(1:10),1).NE.10) CALL ABORT() 1 Error: 'dim' argument of 'size' intrinsic at (1) is not a valid dimension index Compiles just fine with ifort, nagf95 and g95. -- burnus at gcc dot gnu dot org changed: What|Removed |Added Status|UNCONFIRMED |NEW Ever Confirmed|0 |1 Keywords||rejects-valid Last reconfirmed|-00-00 00:00:00 |2007-02-20 14:04:36 date|| Summary|incorrect error message for |size with initialization |valid code |expression value for dim= is ||rejected http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30882