summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjvdelisle <jvdelisle@138bc75d-0d04-0410-961f-82ee72b054a4>2012-12-27 20:13:35 +0000
committerjvdelisle <jvdelisle@138bc75d-0d04-0410-961f-82ee72b054a4>2012-12-27 20:13:35 +0000
commit9a89ffd435265828cfe205fa0458dc97a845cb6d (patch)
treeaaa987e85cee251300c69f6ccfd595e05519fa39
parent60c59b896e6915c9047effb8949092787f73c0aa (diff)
downloadgcc-9a89ffd435265828cfe205fa0458dc97a845cb6d.tar.gz
2012-12-27 Jerry DeLisle <jvdelisle@gcc.gnu.org>
PR fortran/48960 * gfortran.dg/newunit_3.f90: New. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@194738 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/testsuite/ChangeLog5
-rw-r--r--gcc/testsuite/gfortran.dg/newunit_3.f906
2 files changed, 11 insertions, 0 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 1237fb9bdf9..ffe56e980ff 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,5 +1,10 @@
2012-12-27 Jerry DeLisle <jvdelisle@gcc.gnu.org>
+ PR fortran/48960
+ * gfortran.dg/newunit_3.f90: New.
+
+2012-12-27 Jerry DeLisle <jvdelisle@gcc.gnu.org>
+
PR fortran/48976
* gfortran.dg/inquire_15.f90: New.
diff --git a/gcc/testsuite/gfortran.dg/newunit_3.f90 b/gcc/testsuite/gfortran.dg/newunit_3.f90
new file mode 100644
index 00000000000..b79a970a117
--- /dev/null
+++ b/gcc/testsuite/gfortran.dg/newunit_3.f90
@@ -0,0 +1,6 @@
+! PR48960 On ERROR newunit should not modify user variable.
+program test_newunit
+ integer :: st, un = 0
+ open (newunit=un, file='nonexisting.dat', status='old', iostat=st)
+ if (un /= 0) call abort
+end program test_newunit