From 9ad55c33ae2d0c410fbc563fd59e8edb37a48b8b Mon Sep 17 00:00:00 2001
From: Jerry DeLisle <jvdelisle@gcc.gnu.org>
Date: Sun, 7 Jun 2009 18:57:43 +0000
Subject: re PR fortran/40008 (F2008: Add NEWUNIT= for OPEN statement)

2009-05-31  Jerry DeLisle  <jvdelisle@gcc.gnu.org>

	PR fortran/40008
	* gfortran.h (gfc_open): Add newunit expression to structure.
	* io.c (io_tag): Add new unit tag and fix whitespace.
	(match_open_element): Add matching for newunit.
	(gfc_free_open): Free the newunit expression.
	(gfc_resolve_open): Add newunit to resolution and check constraints.
	(gfc_resolve_close): Add check for non-negative unit.
	(gfc_resolve_filepos): Likewise.
	(gfc_resolve_dt): Likewise.
	* trans-io.c (set_parameter_value): Build runtime checks for unit
	numbers within range of kind=4 integer. (gfc_trans_open) Set the
	newunit parameter.
	* ioparm.def (IOPARM): Define the newunit parameter as a pointer
	to GFC_INTEGER_4, pint4.

From-SVN: r148252
---
 gcc/fortran/ioparm.def | 1 +
 1 file changed, 1 insertion(+)

(limited to 'gcc/fortran/ioparm.def')

diff --git a/gcc/fortran/ioparm.def b/gcc/fortran/ioparm.def
index ddef693..7de7a51 100644
--- a/gcc/fortran/ioparm.def
+++ b/gcc/fortran/ioparm.def
@@ -49,6 +49,7 @@ IOPARM (open,    encoding,	1 << 19, char1)
 IOPARM (open,    round,		1 << 20, char2)
 IOPARM (open,    sign,		1 << 21, char1)
 IOPARM (open,    asynchronous,	1 << 22, char2)
+IOPARM (open,    newunit,	1 << 23, pint4)
 IOPARM (close,   common,	0,	 common)
 IOPARM (close,   status,	1 << 7,  char1)
 IOPARM (filepos, common,	0,	 common)
-- 
cgit v1.1

