-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
newunit
specifier for opening files
#455
Comments
This is definitely F2008, so might not be acceptable, given the current coding standards. |
Yea I think it's a good idea to help bring CABLE into the 2010s, although I don't think it's that relevant to that PR. Could extend the scope of the PR to being a modernisation of reading namelists. |
I don't think we're meeting any standards at the moment, so I wouldn't worry about it being a F2008 addition. |
@ccarouge mentioned that we need to follow the JULES standards, and those say Fortran 95/2003 only 😢 |
Are you sure? This conflicts with conversations we had in slack yesterday, where the LFRic Coding Standards were the standards we wanted to follow. Based off the comments and the crosstable linked in this forum post, I thought we came to the conclusion that standards/features up to F2008 were allowable. |
Okay, chatted with @ccarouge and LFRIc standards are the way to go 🎉 |
I have made a start on this issue, including the |
# CABLE Thank you for submitting a pull request to the CABLE Project. ## Description Extend the use of the ```NEWUNIT=``` specifier for acquiring io units to the rest of the active ```OPEN``` calls in the code. There is one exception, in the calls found within ```core/biogeophys/cable_diag.F90```. The units are handled a bit strangely here, with one being defined dependent on the other. Looks like it might interact with the UM coupling in a specific way, so I've left it as is at the moment. Fixes #455 ## Type of change - Fortran standards update ## Checklist - [ ] The new content is accessible and located in the appropriate section. - [ ] I have checked that links are valid and point to the intended content. - [ ] I have checked my code/text and corrected any misspellings
Maybe a good place to start introducing the
newunit
specifier?CABLE/src/offline/cable_driver_init.F90
Lines 98 to 100 in 529e83c
Suggestion:
with
unit
being an integer to be declared above.This is safer and easier to read (here,
10
is a magic number)Originally posted by @micaeljtoliveira in #440 (comment)
The text was updated successfully, but these errors were encountered: