From 8a50466a6c44dbbeda8e164b4fe3456919623f02 Mon Sep 17 00:00:00 2001 From: fxcoudert Date: Mon, 1 Aug 2005 21:13:39 +0000 Subject: [PATCH] PR libfortran/23178 * intrinsics/flush.c (flush_i8): Add function flush_i8. Update copyright years. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@102641 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/fortran/ChangeLog | 4 ++-- libgfortran/ChangeLog | 6 ++++++ libgfortran/intrinsics/flush.c | 25 ++++++++++++++++++++++++- 3 files changed, 32 insertions(+), 3 deletions(-) diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index 1a04beb6058..d9e7ec95773 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,7 +1,7 @@ 2005-07-31 Jerry DeLisle - * intrinsic.texi: Add documentation for exponent, floor, and fnum and - fix description of ceiling in index. + * intrinsic.texi: Add documentation for exponent, floor, and fnum and + fix description of ceiling in index. 2005-07-31 Steven Bosscher diff --git a/libgfortran/ChangeLog b/libgfortran/ChangeLog index 27bb48378ef..cdd3f118216 100644 --- a/libgfortran/ChangeLog +++ b/libgfortran/ChangeLog @@ -1,3 +1,9 @@ +2005-08-01 Francois-Xavier Coudert + + PR libfortran/23178 + * intrinsics/flush.c (flush_i8): Add function flush_i8. Update + copyright years. + 2005-07-31 Francois-Xavier Coudert PR libfortran/21787 diff --git a/libgfortran/intrinsics/flush.c b/libgfortran/intrinsics/flush.c index 40335f9e2da..7e1c98122f7 100644 --- a/libgfortran/intrinsics/flush.c +++ b/libgfortran/intrinsics/flush.c @@ -1,5 +1,5 @@ /* Implementation of the FLUSH intrinsic. - Copyright (C) 2004 Free Software Foundation, Inc. + Copyright (C) 2004, 2005 Free Software Foundation, Inc. Contributed by Steven G. Kargl . This file is part of the GNU Fortran 95 runtime library (libgfortran). @@ -75,3 +75,26 @@ flush_i4 (GFC_INTEGER_4 *unit) flush (us->s); } } + + +extern void flush_i8 (GFC_INTEGER_8 *); +export_proto(flush_i8); + +void +flush_i8 (GFC_INTEGER_8 *unit) +{ + gfc_unit *us; + + /* flush all streams */ + if (unit == NULL) + { + us = g.unit_root; + recursive_flush(us); + } + else + { + us = find_unit(*unit); + if (us != NULL) + flush (us->s); + } +} -- 2.11.0