From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3776 invoked by alias); 13 Jun 2008 13:30:56 -0000 Received: (qmail 2192 invoked by uid 48); 13 Jun 2008 13:30:10 -0000 Date: Fri, 13 Jun 2008 13:30:00 -0000 Message-ID: <20080613133010.2191.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug fortran/36517] Type-spec in array constructor: Invalid error for -std=f2003/f2008 In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "burnus at gcc dot gnu dot org" 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: 2008-06/txt/msg00848.txt.bz2 ------- Comment #2 from burnus at gcc dot gnu dot org 2008-06-13 13:30 ------- Daniel, as you have implemented the constructor with type spec, maybe you have an idea how to fix this best. The error message is generated in decl.c's gfc_set_constant_character_len. The problem is that for -std=f2003 the same error is generated as if no type-spec were present; gfc_set_constant_character_len is called at three places (with argument array=true). I believe we forgot to test character string when implementing it - and characters are always special due to the LENGTH type parameter. (The length-type parameter of derived types will also be fun, but it will probably not be implemented soon.) -- burnus at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |d at domob dot eu http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36517