Skip to content

Commit

Permalink
Fix CCPP Fortran parser / build error with tropopause_find (#310)
Browse files Browse the repository at this point in the history
The CCPP Fortran parser is not able to read module variables of
character type defined with the `shr_kind_cl` parameter size.

The `tropopause_climo_file` variable does not need to be a CCPP variable
anyway so it has been removed. This will fix the build process again.

Verified that it builds (need to either remove `tropopause_diagnostics`
from tropopause_find test SDF -or- merge the history PR) and runs with
CAM snapshot.
  • Loading branch information
jimmielin authored Oct 8, 2024
2 parents 0b6a468 + 9f1f669 commit ebe5516
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 10 deletions.
7 changes: 3 additions & 4 deletions src/physics/utils/tropopause_climo_read.F90
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ module tropopause_climo_read
public :: tropopause_climo_readnl
public :: tropopause_climo_read_file

! Private module data
character(len=shr_kind_cl) :: tropopause_climo_file = unset_str

!> \section arg_table_tropopause_climo_read Argument Table
!! \htmlinclude tropopause_climo_read.html
! months in year for climatological tropopause pressure data
Expand All @@ -28,9 +31,6 @@ module tropopause_climo_read
! monthly day-of-year times corresponding to climatological data (12)
real(kind_phys), public, allocatable :: tropp_days(:)

! Private module data
character(len=shr_kind_cl) :: tropopause_climo_file = unset_str

contains
! Read namelist variable tropopause_climo_file.
! Containing this within CAM-SIMA instead of within scheme as otherwise the climo filepath
Expand Down Expand Up @@ -235,7 +235,6 @@ subroutine tropopause_climo_read_file()
!--------------------------------------------------------
call mark_as_initialized('tropopause_air_pressure_from_climatology_dataset')
call mark_as_initialized('tropopause_calendar_days_from_climatology')
call mark_as_initialized('filename_of_tropopause_climatology')

end subroutine tropopause_climo_read_file
end module tropopause_climo_read
6 changes: 0 additions & 6 deletions src/physics/utils/tropopause_climo_read.meta
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,3 @@
units = 1
type = real | kind = kind_phys
dimensions = (number_of_months_in_year)
[ tropopause_climo_file ]
standard_name = filename_of_tropopause_climatology
long_name = File path to tropopause climatology file
units = none
type = character | kind = len=256
dimensions = ()

0 comments on commit ebe5516

Please sign in to comment.