From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2259 invoked by alias); 27 May 2013 16:09:39 -0000 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 Received: (qmail 2201 invoked by uid 48); 27 May 2013 16:09:32 -0000 From: "bugs at stellardeath dot org" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/57435] New: Ice on invalid: check_for_ambiguous Date: Mon, 27 May 2013 16:09: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-Version: 4.9.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: minor X-Bugzilla-Who: bugs at stellardeath dot org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter attachments.created Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2013-05/txt/msg01904.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57435 Bug ID: 57435 Summary: Ice on invalid: check_for_ambiguous Product: gcc Version: 4.9.0 Status: UNCONFIRMED Severity: minor Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: bugs at stellardeath dot org Created attachment 30205 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=30205&action=edit Minimal test case When trying to reduce a test-case with "delta", I stumbled upon this (unrelated) invalid code-snippet that triggers an ICE: > cat gfortran_check_for_ambiguous.f90 > ~/sys/bin/gfortran gfortran_check_for_ambiguous.f90 gfortran_check_for_ambiguous.f90:4.15: use precision 1 Error: Unexpected USE statement in CONTAINS section at (1) gfortran_check_for_ambiguous.f90:5.19: module stressten_rt 1 Error: Unexpected MODULE statement in CONTAINS section at (1) gfortran_check_for_ambiguous.f90:6.15: use precision 1 Error: Unexpected USE statement in CONTAINS section at (1) f951: internal compiler error: Segmentation fault 0x9b710f crash_signal ../.././gcc/toplev.c:333 0x5b4f13 check_for_ambiguous ../.././gcc/fortran/module.c:4535 0x5b4f13 read_module ../.././gcc/fortran/module.c:4731 0x5b4f13 gfc_use_module ../.././gcc/fortran/module.c:6406 0x5b73d3 gfc_use_modules() ../.././gcc/fortran/module.c:6530 0x5bc267 use_modules ../.././gcc/fortran/parse.c:86 0x5bdaf4 decode_statement ../.././gcc/fortran/parse.c:301 0x5bedf4 next_free ../.././gcc/fortran/parse.c:784 0x5bedf4 next_statement ../.././gcc/fortran/parse.c:977 0x5c165f parse_contained ../.././gcc/fortran/parse.c:4006 0x5c159e parse_progunit ../.././gcc/fortran/parse.c:4192 0x5c212a gfc_parse_file() ../.././gcc/fortran/parse.c:4597 0x5fe5a5 gfc_be_parse_file ../.././gcc/fortran/f95-lang.c:189 Please submit a full bug report, with preprocessed source if appropriate. Please include the complete backtrace with any bug report. See for instructions. > The gfortran version I used was a self-compiled version from trunk: > ~/sys/bin/gfortran --version GNU Fortran (GCC) 4.9.0 20130517 (experimental) Copyright (C) 2013 Free Software Foundation, Inc. GNU Fortran comes with NO WARRANTY, to the extent permitted by law. You may redistribute copies of GNU Fortran under the terms of the GNU General Public License. For more information about these matters, see the file named COPYING It also seems to trigger an ICE in 4.8.0, but behaves correctly in 4.7.2.