Skip to content

Commit

Permalink
check tableEnd efficiently
Browse files Browse the repository at this point in the history
  • Loading branch information
weiyuan-jiang committed Nov 13, 2024
1 parent 18567fa commit cf60fdb
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Changed

- refactored tableEnd check
- Added commandline options to `checkpoint_benchmark.x` and `restart_benchmark.x` to allow for easier testing of different configurations. Note that the old configuration file style of input is allowed via the `--config_file` option (which overrides any other command line options)
- Update ESMF version for Baselibs to match that of Spack for consistency
- Update `components.yaml`
Expand Down
5 changes: 2 additions & 3 deletions gridcomps/Cap/MAPL_CapGridComp.F90
Original file line number Diff line number Diff line change
Expand Up @@ -979,12 +979,11 @@ function get_vec_from_config(config, key, rc) result(vec)

cap_import = ""
if (present) then

do while(trim(cap_import) /= "::")
do while( .true.)
call ESMF_ConfigNextLine(config, tableEnd=tableEnd, _RC)
if (tableEnd) exit
call ESMF_ConfigGetAttribute(config, cap_import, _RC)
if (trim(cap_import) /= "::") call vec%push_back(trim(cap_import))
call vec%push_back(trim(cap_import))
end do
end if
_RETURN(_SUCCESS)
Expand Down

0 comments on commit cf60fdb

Please sign in to comment.