This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/26017] allocate (a(1:-1)) should yield zero-sized array



------- Comment #6 from tkoenig at gcc dot gnu dot org  2006-04-16 20:29 -------
Subject: Bug 26017

Author: tkoenig
Date: Sun Apr 16 20:29:24 2006
New Revision: 112988

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=112988
Log:
2006-04-16  Thomas Koenig  <Thomas.Koenig@online.de>

        PR fortran/26017
        * trans-array.c(gfc_array_init_size):  Introduce or_expr
        which is true if the size along any dimension
        is negative.  Create a temporary variable with base
        name size.  If or_expr is true, set the temporary to 0,
        to the normal size otherwise.

2006-04-16  Thomas Koenig  <Thomas.Koenig@online.de>

        * gfortran.dg/allocate_zerosize_1.f90:  New test.


Added:
    trunk/gcc/testsuite/gfortran.dg/allocate_zerosize_1.f90
Modified:
    trunk/gcc/fortran/ChangeLog
    trunk/gcc/fortran/trans-array.c
    trunk/gcc/testsuite/ChangeLog


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26017


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]