From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3518 invoked by alias); 9 Jan 2012 18:23:39 -0000 Received: (qmail 3506 invoked by uid 22791); 9 Jan 2012 18:23:37 -0000 X-SWARE-Spam-Status: No, hits=-2.9 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from localhost (HELO gcc.gnu.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 09 Jan 2012 18:23:24 +0000 From: "mario-baumann at web dot de" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/51800] New: Error: Automatic array 'dummy' at (1) cannot have an initializer Date: Mon, 09 Jan 2012 18:23:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: fortran X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: mario-baumann at web dot de X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Message-ID: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2012-01/txt/msg00898.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51800 Bug #: 51800 Summary: Error: Automatic array 'dummy' at (1) cannot have an initializer Classification: Unclassified Product: gcc Version: 4.7.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran AssignedTo: unassigned@gcc.gnu.org ReportedBy: mario-baumann@web.de Created attachment 26282 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=26282 fortran90 source file Hi Gfortran Team, compilation of the attached source file failed if using the both compiler options -fno-automatic and -finit-local-zero. > gfortran -c -m32 -O0 -fno-automatic -finit-local-zero foo.f90 foo.f90:6.27: INTEGER :: DUMMY(1:N) 1 Error: Automatic array 'dummy' at (1) cannot have an initializer It works fine if removing at least one of the both options above. ------------------------------------------------------------------------------- > uname -a Linux ahsoka.intec.dom 2.6.32-220.2.1.el6.x86_64 #1 SMP Tue Dec 13 16:21:34 EST 2011 x86_64 x86_64 x86_64 GNU/Linux > rpm -qa "glibc*" | grep -e 'glibc-[0-9]' | sort -u glibc-2.12-1.47.el6.i686 glibc-2.12-1.47.el6.x86_64 > g++ -v Using built-in specs. COLLECT_GCC=g++ COLLECT_LTO_WRAPPER=/app2/gcc/4.7.0-20120109-svn183001/i686/libexec/gcc/i686-unknown-linux-gnu/4.7.0/lto-wrapper Target: i686-unknown-linux-gnu Configured with: ./configure --prefix=/app2/gcc/4.7.0-20120109-svn183001/i686 --enable-languages=c,c++,fortran --disable-nls --with-gmp=/app2/gcc/4.7.0-20120109-svn183001/i686/aux --with-mpfr=/app2/gcc/4.7.0-20120109-svn183001/i686/aux --with-mpc=/app2/gcc/4.7.0-20120109-svn183001/i686/aux --with-ppl=/app2/gcc/4.7.0-20120109-svn183001/i686/aux --with-cloog=/app2/gcc/4.7.0-20120109-svn183001/i686/aux --disable-multilib --build=i686-unknown-linux-gnu Thread model: posix gcc version 4.7.0 20120109 (experimental) (GCC) > ld -v GNU ld (GNU Binutils) 2.22.51.20120109