trans-types.c (gfc_init_kinds): Only pass float...

* fortran/trans-types.c (gfc_init_kinds): Only pass float, double,
	and long double floating point types through to Fortran compiler.

From-SVN: r104892
This commit is contained in:
Steve Ellcey 2005-10-03 15:29:30 +00:00 committed by Steve Ellcey
parent 0b494699b4
commit 216ac520d4
2 changed files with 13 additions and 0 deletions

View File

@ -1,3 +1,8 @@
2005-10-03 Steve Ellcey <sje@cup.hp.com>
* fortran/trans-types.c (gfc_init_kinds): Only pass float, double,
and long double floating point types through to Fortran compiler.
2005-10-03 Francois-Xavier Coudert <coudert@clipper.ens.fr>
PR fortran/20120

View File

@ -152,6 +152,14 @@ gfc_init_kinds (void)
if (!targetm.scalar_mode_supported_p (mode))
continue;
/* Only let float/double/long double go through because the fortran
library assumes these are the only floating point types. */
if (mode != TYPE_MODE (float_type_node)
&& (mode != TYPE_MODE (double_type_node))
&& (mode != TYPE_MODE (long_double_type_node)))
continue;
/* Let the kind equal the precision divided by 8, rounding up. Again,
this insulates the programmer from the underlying byte size.