[gfortran] Fix PR 17776: Add SYSTEM intrinsics
Tobias Schlüter
tobias.schlueter@physik.uni-muenchen.de
Sat Oct 2 20:25:00 GMT 2004
We were missing the SYSTEM intrinsic which is used to call the C library
function system(3).
Added by this. I attached two patches: one to the library, one to the
compiler, and the new file libgfortran/intrinsics/system.c
Built, tested and verified. Do we need a testcase? OK?
- Tobi
2004-10-02 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
PR fortran/17776
fortran/
* check.c (gfc_check_system_sub): New function.
* gfortran.h (gfc_generic_isym_id): Add GFC_ISYM_SYSTEM.
* intrinsic.c (add_functions): Add 'system'.
(add_subroutines): Add 'system'.
* intrinsic.h (gfc_check_etime_sub, gfc_check_getcwd_sub):
Move prototypes to other suborutines.
(gfc_check_system_sub, gfc_resolve_system, gfc_resolve_system_sub):
Add prototype.
(gfc_resolve_system_clock): Fix formatting of prototype.
* iresolve.c (gfc_resolve_system, gfc_resolve_system_sub): New
functions.
* trans-intrinsic.c (gfc_conv_intrinsic_function): Deal with
GFC_ISYM_SYSTEM.
libgfortran/
* intrinsics/system.c: New file.
* Makefile.am: Add new file.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 17776.diff
Type: text/x-patch
Size: 5955 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/fortran/attachments/20041002/94445819/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 17776lib.diff
Type: text/x-patch
Size: 481 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/fortran/attachments/20041002/94445819/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: system.c
Type: text/x-csrc
Size: 1858 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/fortran/attachments/20041002/94445819/attachment-0002.bin>
More information about the Fortran
mailing list