Last change
on this file since 5159 was
5119,
checked in by abarral, 5 months ago
|
enforce PRIVATE by default in several modules, expose PUBLIC as needed
move eigen.f90 to obsolete/
(lint) aslong the way
|
-
Property copyright set to
Name of program: LMDZ Creation date: 1984 Version: LMDZ5 License: CeCILL version 2 Holder: Laboratoire de m\'et\'eorologie dynamique, CNRS, UMR 8539 See the license file in the root directory
|
File size:
428 bytes
|
Line | |
---|
1 | module lmdz_new_unit |
---|
2 | |
---|
3 | IMPLICIT NONE; PRIVATE |
---|
4 | PUBLIC new_unit |
---|
5 | |
---|
6 | CONTAINS |
---|
7 | |
---|
8 | ! Returns an existing unit id that isn't already opened |
---|
9 | SUBROUTINE new_unit(unit) |
---|
10 | INTEGER, INTENT(OUT):: unit |
---|
11 | |
---|
12 | LOGICAL opened, exist |
---|
13 | |
---|
14 | unit = 0 |
---|
15 | DO |
---|
16 | INQUIRE(unit=unit, opened=opened, exist=exist) |
---|
17 | IF (exist .AND. .NOT. opened) RETURN |
---|
18 | unit = unit + 1 |
---|
19 | END DO |
---|
20 | |
---|
21 | END SUBROUTINE new_unit |
---|
22 | |
---|
23 | END MODULE lmdz_new_unit |
---|
Note: See
TracBrowser
for help on using the repository browser.