This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
Re: [patch,fortran] texi patch: fix CHMOD entry, list volatile and internal-file namelist support
- From: Tobias Burnus <burnus at net-b dot de>
- Cc: fortran at gcc dot gnu dot org, gcc-patches at gcc dot gnu dot org
- Date: Wed, 08 Nov 2006 10:25:47 +0100
- Subject: Re: [patch,fortran] texi patch: fix CHMOD entry, list volatile and internal-file namelist support
- References: <45509290.9030008@net-b.de> <4550D8C1.9030507@codesourcery.com>
Hi,
I checked in the following to patches:
a) CHMOD and Fortran 2003 volatile and internal-file namelist support
into the trunk
b) CHMOD into the 4.2 branch
They were "make info" and "make fortran.pdf" tested.
Tobias
Index: gcc/fortran/ChangeLog
===================================================================
--- gcc/fortran/ChangeLog (Revision 118577)
+++ gcc/fortran/ChangeLog (Arbeitskopie)
@@ -1,3 +1,7 @@
+2006-11-08 Tobias Burnus <burnus@net-b.de>
+
+ * intrinsic.texi: Correct CHMOD entry.
+
2006-11-06 Brooks Moses <brooks.moses@codesourcery.com>
* intrinsic.texi: Added documentation for FTELL, GETLOG, and
Index: gcc/fortran/intrinsic.texi
===================================================================
--- gcc/fortran/intrinsic.texi (Revision 118577)
+++ gcc/fortran/intrinsic.texi (Arbeitskopie)
@@ -1910,16 +1910,21 @@
@item @emph{Description}:
@code{CHMOD} changes the permissions of a file. This function invokes
@code{/bin/chmod} and might therefore not work on all platforms.
-@code{CHMOD} as an intrinsic function is not implemented in GNU Fortran.
+This intrinsic is provided in both subroutine and function forms; however,
+only one form can be used in any given program unit.
+
@item @emph{Standard}:
GNU extension
@item @emph{Class}:
-Subroutine
+Subroutine, non-elemental function
@item @emph{Syntax}:
-@code{CHMOD(NAME, MODE[, STATUS])}
+@multitable @columnfractions .80
+@item @code{CALL CHMOD(NAME, MODE[, STATUS])}
+@item @code{STATUS = CHMOD(NAME, MODE)}
+@end multitable
@item @emph{Arguments}:
@multitable @columnfractions .15 .80
@@ -1936,7 +1941,12 @@
@code{0} on success and non-zero otherwise.
@end multitable
+@item @emph{Return value}:
+In either syntax, @var{STATUS} is set to @code{0} on success and non-zero
+otherwise.
+
@item @emph{Example}:
+@code{CHMOD} as subroutine
@smallexample
program chmod_test
implicit none
@@ -1945,6 +1955,15 @@
print *, 'Status: ', status
end program chmod_test
@end smallexample
+@code{CHMOD} as non-elemental function:
+@smallexample
+program chmod_test
+ implicit none
+ integer :: status
+ status = chmod('test.dat','u+x')
+ print *, 'Status: ', status
+end program chmod_test
+@end smallexample
@item @emph{Specific names}:
@item @emph{See also}:
Index: gcc/fortran/gfortran.texi
===================================================================
--- gcc/fortran/gfortran.texi (Revision 118577)
+++ gcc/fortran/gfortran.texi (Arbeitskopie)
@@ -1380,8 +1380,14 @@
The @code{OPEN} statement supports the @code{ACCESS='STREAM'} specifier,
allowing I/O without any record structure.
+@item
+Namelist input/output for internal files.
+@item
+@cindex @code{VOLATILE}
+The @code{VOLATILE} statement and attribute.
+
@end itemize
Index: gcc/fortran/ChangeLog
===================================================================
--- gcc/fortran/ChangeLog (Revision 118577)
+++ gcc/fortran/ChangeLog (Arbeitskopie)
@@ -1,5 +1,11 @@
-2006-11-07 Paul Thomas <pault@gcc.gnu.org>
+2006-11-08 Tobias Burnus <burnus@net-b.de>
+ * gfortran.texi: Add volatile and internal-file
+ namelist to Fortran 2003 status.
+ * intrinsic.texi: Correct CHMOD entry.
+
+2006-11-07 Paul Thomas <pault@gcc.gnu.org>
+
PR fortran/29539
PR fortran/29634
* decl.c (variable_decl): Add test for presence of proc_name.
Index: gcc/fortran/intrinsic.texi
===================================================================
--- gcc/fortran/intrinsic.texi (Revision 118577)
+++ gcc/fortran/intrinsic.texi (Arbeitskopie)
@@ -1910,16 +1910,21 @@
@item @emph{Description}:
@code{CHMOD} changes the permissions of a file. This function invokes
@code{/bin/chmod} and might therefore not work on all platforms.
-@code{CHMOD} as an intrinsic function is not implemented in GNU Fortran.
+This intrinsic is provided in both subroutine and function forms; however,
+only one form can be used in any given program unit.
+
@item @emph{Standard}:
GNU extension
@item @emph{Class}:
-Subroutine
+Subroutine, non-elemental function
@item @emph{Syntax}:
-@code{CHMOD(NAME, MODE[, STATUS])}
+@multitable @columnfractions .80
+@item @code{CALL CHMOD(NAME, MODE[, STATUS])}
+@item @code{STATUS = CHMOD(NAME, MODE)}
+@end multitable
@item @emph{Arguments}:
@multitable @columnfractions .15 .80
@@ -1936,7 +1941,12 @@
@code{0} on success and non-zero otherwise.
@end multitable
+@item @emph{Return value}:
+In either syntax, @var{STATUS} is set to @code{0} on success and non-zero
+otherwise.
+
@item @emph{Example}:
+@code{CHMOD} as subroutine
@smallexample
program chmod_test
implicit none
@@ -1945,6 +1955,15 @@
print *, 'Status: ', status
end program chmod_test
@end smallexample
+@code{CHMOD} as non-elemental function:
+@smallexample
+program chmod_test
+ implicit none
+ integer :: status
+ status = chmod('test.dat','u+x')
+ print *, 'Status: ', status
+end program chmod_test
+@end smallexample
@item @emph{Specific names}:
@item @emph{See also}: