From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5056 invoked by alias); 5 Feb 2015 08:16:38 -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 5019 invoked by uid 48); 5 Feb 2015 08:16:35 -0000 From: "pault at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/64943] New: No error on ultimate allocatable components in IO list Date: Thu, 05 Feb 2015 08:16: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: 5.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: pault at gcc dot gnu.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 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: 2015-02/txt/msg00424.txt.bz2 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64943 Bug ID: 64943 Summary: No error on ultimate allocatable components in IO list Product: gcc Version: 5.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: pault at gcc dot gnu.org With this wrong code (other brand: Variables containing ultimate allocatable array components are forbidden from appearing directly in input/output lists. print *, TestReference([Test(99), Test(199)])): type :: Test integer :: i end type type :: TestReference class(Test), allocatable :: test(:) end type print *, TestReference([Test(99), Test(199)]) end 5.0 gives: f951: internal compiler error: Bad IO basetype (7) 0x62a1fb gfc_internal_error(char const*, ...) ../../trunk/gcc/fortran/error.c:1486 0x71738b transfer_expr ../../trunk/gcc/fortran/trans-io.c:2265 0x71724a transfer_expr ../../trunk/gcc/fortran/trans-io.c:2259 0x71ad25 gfc_trans_transfer(gfc_code*) ../../trunk/gcc/fortran/trans-io.c:2395 0x6ba7e7 trans_code ../../trunk/gcc/fortran/trans.c:1853 0x718790 build_dt ../../trunk/gcc/fortran/trans-io.c:1921 0x6ba807 trans_code ../../trunk/gcc/fortran/trans.c:1825 0x6e6008 gfc_generate_function_code(gfc_namespace*) ../../trunk/gcc/fortran/trans-decl.c:5842 0x6778c0 translate_all_program_units ../../trunk/gcc/fortran/parse.c:5341 0x6778c0 gfc_parse_file() ../../trunk/gcc/fortran/parse.c:5538 0x6b7675 gfc_be_parse_file ../../trunk/gcc/fortran/f95-lang.c:228