New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
Changeset 12202 for NEMO/branches/2019/dev_r12072_MERGE_OPTION2_2019/src/TOP/trcnam.F90 – NEMO

Ignore:
Timestamp:
2019-12-12T09:59:50+01:00 (4 years ago)
Author:
cetlod
Message:

dev_merge_option2 : merge in dev_r11613_ENHANCE-04_namelists_as_internalfiles

File:
1 edited

Legend:

Unmodified
Added
Removed
  • NEMO/branches/2019/dev_r12072_MERGE_OPTION2_2019/src/TOP/trcnam.F90

    r12110 r12202  
    108108      IF(lwp) WRITE(numout,*) '~~~~~~~~~~~' 
    109109      ! 
    110       CALL ctl_opn( numnat_ref, 'namelist_top_ref'   , 'OLD'    , 'FORMATTED', 'SEQUENTIAL', -1, numout, .FALSE. ) 
    111       CALL ctl_opn( numnat_cfg, 'namelist_top_cfg'   , 'OLD'    , 'FORMATTED', 'SEQUENTIAL', -1, numout, .FALSE. ) 
     110      CALL load_nml( numnat_ref, 'namelist_top_ref' , numout, lwm ) 
     111      CALL load_nml( numnat_cfg, 'namelist_top_cfg' , numout, lwm ) 
    112112      IF(lwm) CALL ctl_opn( numont, 'output.namelist.top', 'UNKNOWN', 'FORMATTED', 'SEQUENTIAL', -1, numout, .FALSE., 1 ) 
    113113      ! 
    114       REWIND( numnat_ref )              ! Namelist namtrc in reference namelist : Passive tracer variables 
    115114      READ  ( numnat_ref, namtrc_run, IOSTAT = ios, ERR = 901) 
    116115901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namtrc in reference namelist' ) 
    117       REWIND( numnat_cfg )              ! Namelist namtrc in configuration namelist : Passive tracer variables 
    118116      READ  ( numnat_cfg, namtrc_run, IOSTAT = ios, ERR = 902 ) 
    119117902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namtrc in configuration namelist' ) 
     
    158156      IF(lwp) WRITE(numout,*) '~~~~~~~~~~~' 
    159157 
    160       REWIND( numnat_ref )              ! Namelist namtrc in reference namelist : Passive tracer variables 
    161158      READ  ( numnat_ref, namtrc, IOSTAT = ios, ERR = 901) 
    162159901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namtrc in reference namelist' ) 
    163       REWIND( numnat_cfg )              ! Namelist namtrc in configuration namelist : Passive tracer variables 
    164160      READ  ( numnat_cfg, namtrc, IOSTAT = ios, ERR = 902 ) 
    165161902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namtrc in configuration namelist' ) 
     
    229225      IF( ll_cfc .OR. ln_c14 ) THEN 
    230226        !                             ! Open namelist files 
    231         CALL ctl_opn( numtrc_ref, 'namelist_trc_ref'   ,     'OLD', 'FORMATTED', 'SEQUENTIAL', -1, numout, .FALSE. ) 
    232         CALL ctl_opn( numtrc_cfg, 'namelist_trc_cfg'   ,     'OLD', 'FORMATTED', 'SEQUENTIAL', -1, numout, .FALSE. ) 
     227        CALL load_nml( numtrc_ref, 'namelist_trc_ref' , numout, lwm ) 
     228        CALL load_nml( numtrc_cfg, 'namelist_trc_cfg' , numout, lwm ) 
    233229        IF(lwm) CALL ctl_opn( numonr, 'output.namelist.trc', 'UNKNOWN', 'FORMATTED', 'SEQUENTIAL', -1, numout, .FALSE. ) 
    234230        ! 
     
    262258      ALLOCATE( ln_trdtrc(jptra) )  
    263259      ! 
    264       REWIND( numnat_ref )              ! Namelist namtrc_trd in reference namelist : Passive tracer trends 
    265260      READ  ( numnat_ref, namtrc_trd, IOSTAT = ios, ERR = 905) 
    266261905   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namtrc_trd in reference namelist' ) 
    267       REWIND( numnat_cfg )              ! Namelist namtrc_trd in configuration namelist : Passive tracer trends 
    268262      READ  ( numnat_cfg, namtrc_trd, IOSTAT = ios, ERR = 906 ) 
    269263906   IF( ios >  0 )   CALL ctl_nam ( ios , 'namtrc_trd in configuration namelist' ) 
Note: See TracChangeset for help on using the changeset viewer.