This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/31608] wrong types in character array/scalar binop
- From: "rguenther at suse dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 16 Nov 2007 09:50:35 -0000
- Subject: [Bug fortran/31608] wrong types in character array/scalar binop
- References: <bug-31608-10053@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #62 from rguenther at suse dot de 2007-11-16 09:50 -------
Subject: Re: wrong types in character array/scalar binop
On Fri, 16 Nov 2007, pault at gcc dot gnu dot org wrote:
> ------- Comment #61 from pault at gcc dot gnu dot org 2007-11-16 09:23 -------
> Richard,
>
> I believe that this is the right outcome for achar_4?
>
> (*(char[0:][1:1] *) atmp.4.data)[S.5][1]{lb: 1 sz: 1} =
> *(_gfortran_compare_string (D.529, &(*(char[0:][1:1] *) atmp.2.data)[S.5][1]{lb: 1 sz: 1},
> 1
> , &"a"[1]{lb: 1 sz: 1}) >= 0 && _gfortran_compare_string (D.541,
> &(*(char[0:][1:
> 1] *) atmp.3.data)[S.5][1]{lb: 1 sz: 1}, 1, &"z"[1]{lb: 1 sz: 1}) <= 0 ?
> &char.6
> : &(*(char[0:][1:1] *) atmp.1.data)[S.5][1]{lb: 1 sz: 1});
Twisted, but yes, this looks ok if char.6 is plain 'char'.
Richard.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31608