This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/32968] selected_(int|real)_kind fail with -fdefault-integer-8
- From: "sgk at troutmask dot apl dot washington dot edu" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 2 Aug 2007 23:49:43 -0000
- Subject: [Bug fortran/32968] selected_(int|real)_kind fail with -fdefault-integer-8
- References: <bug-32968-12313@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #9 from sgk at troutmask dot apl dot washington dot edu 2007-08-02 23:49 -------
Subject: Re: selected_(int|real)_kind fail with -fdefault-integer-8
On Thu, Aug 02, 2007 at 11:02:55PM -0000, dominiq at lps dot ens dot fr wrote:
>
>
> ------- Comment #8 from dominiq at lps dot ens dot fr 2007-08-02 23:02 -------
> Subject: Re: selected_(int|real)_kind fail with
> -fdefault-integer-8
>
> > Can you try the attached patch?
>
> It fixes the problem for -fdefault-integer-8, but without it,
> it gives on your test (and others) the infamous:
>
> intrinsic_sir_kind_red.f90:4.3:
>
> end
> 1
> Internal Error at (1):
> intrinsic_sir_kind_red.f90:3.28:
>
> print *, selected_real_kind(i)
> 1
> Can't convert INTEGER(4) to INTEGER(4) at (1)
>
> I think you need the same kind of machinery as for
> PR32954, i.e., change to 4 only if it is different from 4.
That's next. :-)
> BTW, did you consider the second optional argument for
> selected_real_kind(i)?
Yes.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32968