ESCOMP / ESCOMP/CTSM

Cleanup restartvar_{DIMS}d_{TYPE} to ONLY be valid for a 1d interface as we already have a restart_2d_{TYPE}_bounds interface for 2D

Open
#170 2 comments 0 reactions 0 assignees View on GitHub
code health priority: low
Dominant language
Fortran
Stars
352
Forks
361
Avg merge
2d 21h
Merged PRs (30d)
7

Description

**Erik Kluzek < erik > - 2017-06-05 15:50:59 -0600**
**Bugzilla Id:** [2469](http://bugz.cgd.ucar.edu/show_bug.cgi?id=2469)
**Bugzilla Depends:** 2468,
**Bugzilla CC:** andre, dlawren, mvertens, rfisher, sacks,

restUtilMod.F90.in has two interfaces for restartvars, one should really only be used for the 1d interface and the second for the 2d one. The first one is supposed general, but it doesn't do enough checking to be correct for a 2d case. The only valid options are 1d and 2d anyway, so generalizing the first to work for both isn't worth it. So the data array should be data(:) and dim2name removed from the first interface and changed to restartvar_1d_{TYPE}. Note, the other thing that distinguishes the two is the optional arguments: lowerb2, and upperb2 are possible for the 2d case, but not the 1d one. And in the 1d case, dim1name is NOT a required argument like it is in the 2d one (along with dim2name).

Bug 2468 came to be because of this problem since switchdim is really required when dimname2name is set.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.