Opened 6 years ago

Closed 6 years ago

#523 closed enhancement (fixed)

Remove redundant variables

Reported by: Ian Culverwell Owned by: Ian Culverwell
Priority: normal Milestone: 9.1
Component: ROPP (all) Version: 9.0
Keywords: Cc:

Description

The nagfor compiler provides lots of useful information about redundant variables, like

NAG Fortran Compiler Release 5.2(721)
Warning: ../qc/ropp_qc_ion_bangle.f90, line 199: Unused dummy variable DIAG
         detected at ROPP_QC_ION_BANGLE@<end-of-statement>

Later versions provide more comprehensive checking, and include things like

NAG Fortran Compiler Release 5.3.1(907)
Questionable: ../qc/ropp_qc_omb.f90, line 135: Variable DUMMY set but never referenced

We should probably reduce the number of unused variable if possible Caution is required, however. For example, nagfor5.3 says

Warning: ../ropp/ropp_io_read_ncdf_get.f90, line 3465: Unused dummy variable FILE
Warning: ../ropp/ropp_io_read_ncdf_get.f90, line 3465: Unused local variable LDUM
Warning: ../ropp/ropp_io_read_ncdf_get.f90, line 3611: Unused dummy variable LDUMMY

The last of these is needed to let the operator overloading differentiate between ropp_io_read_ncdf_get_eumdata and ropp_io_read_ncdf_get_otherdata.

Change history (4)

comment:1 by Ian Culverwell, 6 years ago

The first tranche of these removals have been committed at r5118.

comment:2 by Ian Culverwell, 6 years ago

I mean r5518.

comment:3 by Ian Culverwell, 6 years ago

Some more have been made at r5547.

comment:4 by Ian Culverwell, 6 years ago

Resolution: fixed
Status: newclosed

Doesn't crash the overnight test folder, so close ticket.

Note: See TracTickets for help on using tickets.