From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19835 invoked by alias); 25 Mar 2008 12:59:04 -0000 Received: (qmail 19591 invoked by uid 48); 25 Mar 2008 12:58:12 -0000 Date: Tue, 25 Mar 2008 12:59:00 -0000 Message-ID: <20080325125812.19590.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug fortran/27997] Fortran 2003: Support type-spec for array constructor In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "fxcoudert 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-03/txt/msg01979.txt.bz2 ------- Comment #8 from fxcoudert at gcc dot gnu dot org 2008-03-25 12:58 ------- (In reply to comment #6) > Possibly when gfc_convert_expr is called on a string literal? I'm not sure but I think you'd see the same issue on a character variable that is not a constant. gfc_convert_expr() doesn't handle conversion of characters into different strings lengths, and it probably shouldn't be extended to do that (it's a special case that is only used in type-spec array constructors). So we probably need to add some code to handle that instead of calling gfc_convert_expr() when we have character variables. (Maybe a function to do just that already exists in expr.c.) -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27997