[Patch,Fortran] -fcheck=bounds fix; intrinsic.texi: INT*/REAL* documentation
Tobias Burnus
burnus@net-b.de
Tue Jun 9 13:46:00 GMT 2009
Dear all,
here are two minor fixes:
-fcheck=bounds did not always works as an if(f_bounds_check) was left;
found while debugging PR 40383.
When writing the gcc-4.5/changes.html, I realized that INT* and REAL*
were not documented.
Build and regtested on x86-64-linux. I intent to commit the patch as
obvious in a couple of hours, unless someone objects.
Tobias
2009-06-09 Tobias Burnus <burnus@net-b.de>
* trans-decl.c (gfc_generate_function_code): Use gfc_option.rtcheck
instead of flag_bounds_check.
* intrinsic.texi (ISO_FORTRAN_ENV): Document INT{8,16,32,64} and
REAL{32,64,128}.
Index: gcc/fortran/trans-decl.c
===================================================================
--- gcc/fortran/trans-decl.c (revision 148308)
+++ gcc/fortran/trans-decl.c (working copy)
@@ -4185,7 +4185,7 @@ gfc_generate_function_code (gfc_namespac
/* If bounds-checking is enabled, generate code to check passed in actual
arguments against the expected dummy argument attributes (e.g. string
lengths). */
- if (flag_bounds_check)
+ if (gfc_option.rtcheck & GFC_RTCHECK_BOUNDS)
add_argument_checking (&body, sym);
tmp = gfc_trans_code (ns->code);
Index: gcc/fortran/intrinsic.texi
===================================================================
--- gcc/fortran/intrinsic.texi (revision 148308)
+++ gcc/fortran/intrinsic.texi (working copy)
@@ -11241,6 +11241,11 @@ Size in bits of the file-storage unit.
Identifies the preconnected unit identified by the asterisk
(@code{*}) in @code{READ} statement.
+@item @code{INT8}, @code{INT16}, @code{INT32}, @code{INT64}
+Kind type parameters to specify an INTEGER type with a storage
+size of 16, 32, and 64 bits. It is negative if a target platform
+does not support the particular kind.
+
@item @code{IOSTAT_END}:
The value assigned to the variable passed to the IOSTAT= specifier of
an input/output statement if an end-of-file condition occurred.
@@ -11255,8 +11260,15 @@ The size in bits of the numeric storage
@item @code{OUTPUT_UNIT}:
Identifies the preconnected unit identified by the asterisk
(@code{*}) in @code{WRITE} statement.
+
+@item @code{REAL32}, @code{REAL64}, @code{REAL128}
+Kind type parameters to specify a REAL type with a storage
+size of 32, 64, and 128 bits. It is negative if a target platform
+does not support the particular kind.
@end table
+
+
@node ISO_C_BINDING
@section @code{ISO_C_BINDING}
@table @asis
More information about the Fortran
mailing list