aboutsummaryrefslogtreecommitdiff
path: root/libgfortran
diff options
context:
space:
mode:
authorJerry DeLisle <jvdelisle@gcc.gnu.org>2020-01-17 19:36:03 -0800
committerJerry DeLisle <jvdelisle@gcc.gnu.org>2020-01-17 19:36:03 -0800
commite2947cfa2d1d4da13bb298b4f36cd745b007d88d (patch)
tree27af90f4da481d5ceeb85f4142de83fec5139759 /libgfortran
parent92030203c1d284ccaed0037864262ff9181cf965 (diff)
downloadgcc-e2947cfa2d1d4da13bb298b4f36cd745b007d88d.zip
gcc-e2947cfa2d1d4da13bb298b4f36cd745b007d88d.tar.gz
gcc-e2947cfa2d1d4da13bb298b4f36cd745b007d88d.tar.bz2
PR93234 INQUIRE on pre-assigned files of ROUND and SIGN properties
PR libfortran/93234 * io/unit.c (set_internal_unit): Set round and sign flags correctly. * gfortran.dg/inquire_pre.f90: New test.
Diffstat (limited to 'libgfortran')
-rw-r--r--libgfortran/ChangeLog6
-rw-r--r--libgfortran/io/unit.c16
2 files changed, 14 insertions, 8 deletions
diff --git a/libgfortran/ChangeLog b/libgfortran/ChangeLog
index bd2d87e..f546ef8 100644
--- a/libgfortran/ChangeLog
+++ b/libgfortran/ChangeLog
@@ -1,5 +1,11 @@
2020-01-17 Jerry DeLisle <jvdelisle@gcc.gnu.org>
+ PR libfortran/93234
+ * io/unit.c (set_internal_unit): Set round and sign flags
+ correctly.
+
+2020-01-17 Jerry DeLisle <jvdelisle@gcc.gnu.org>
+
PR libfortran/90374
* io/format.c (parse_format_list): Zero width not allowed with
FMT_D.
diff --git a/libgfortran/io/unit.c b/libgfortran/io/unit.c
index c4e1ccb..0030d7e 100644
--- a/libgfortran/io/unit.c
+++ b/libgfortran/io/unit.c
@@ -514,12 +514,12 @@ set_internal_unit (st_parameter_dt *dtp, gfc_unit *iunit, int kind)
iunit->flags.form = FORM_FORMATTED;
iunit->flags.pad = PAD_YES;
iunit->flags.status = STATUS_UNSPECIFIED;
- iunit->flags.sign = SIGN_UNSPECIFIED;
+ iunit->flags.sign = SIGN_PROCDEFINED;
iunit->flags.decimal = DECIMAL_POINT;
iunit->flags.delim = DELIM_UNSPECIFIED;
iunit->flags.encoding = ENCODING_DEFAULT;
iunit->flags.async = ASYNC_NO;
- iunit->flags.round = ROUND_UNSPECIFIED;
+ iunit->flags.round = ROUND_PROCDEFINED;
/* Initialize the data transfer parameters. */
@@ -627,12 +627,12 @@ init_units (void)
u->flags.blank = BLANK_NULL;
u->flags.pad = PAD_YES;
u->flags.position = POSITION_ASIS;
- u->flags.sign = SIGN_UNSPECIFIED;
+ u->flags.sign = SIGN_PROCDEFINED;
u->flags.decimal = DECIMAL_POINT;
u->flags.delim = DELIM_UNSPECIFIED;
u->flags.encoding = ENCODING_DEFAULT;
u->flags.async = ASYNC_NO;
- u->flags.round = ROUND_UNSPECIFIED;
+ u->flags.round = ROUND_PROCDEFINED;
u->flags.share = SHARE_UNSPECIFIED;
u->flags.cc = CC_LIST;
@@ -658,12 +658,12 @@ init_units (void)
u->flags.status = STATUS_OLD;
u->flags.blank = BLANK_NULL;
u->flags.position = POSITION_ASIS;
- u->flags.sign = SIGN_UNSPECIFIED;
+ u->flags.sign = SIGN_PROCDEFINED;
u->flags.decimal = DECIMAL_POINT;
u->flags.delim = DELIM_UNSPECIFIED;
u->flags.encoding = ENCODING_DEFAULT;
u->flags.async = ASYNC_NO;
- u->flags.round = ROUND_UNSPECIFIED;
+ u->flags.round = ROUND_PROCDEFINED;
u->flags.share = SHARE_UNSPECIFIED;
u->flags.cc = CC_LIST;
@@ -689,11 +689,11 @@ init_units (void)
u->flags.status = STATUS_OLD;
u->flags.blank = BLANK_NULL;
u->flags.position = POSITION_ASIS;
- u->flags.sign = SIGN_UNSPECIFIED;
+ u->flags.sign = SIGN_PROCDEFINED;
u->flags.decimal = DECIMAL_POINT;
u->flags.encoding = ENCODING_DEFAULT;
u->flags.async = ASYNC_NO;
- u->flags.round = ROUND_UNSPECIFIED;
+ u->flags.round = ROUND_PROCDEFINED;
u->flags.share = SHARE_UNSPECIFIED;
u->flags.cc = CC_LIST;